From cbfc682f9abc9b4c02ea3c0f63a4403d037f14a4 Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Thu, 16 May 2024 11:43:13 +0400 Subject: Implement at-startup window rule --- wiki/Configuration:-Window-Rules.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'wiki') diff --git a/wiki/Configuration:-Window-Rules.md b/wiki/Configuration:-Window-Rules.md index d4b50f3b..a86a2cb8 100644 --- a/wiki/Configuration:-Window-Rules.md +++ b/wiki/Configuration:-Window-Rules.md @@ -33,6 +33,7 @@ window-rule { match is-active=true match is-focused=false match is-active-in-column=true + match at-startup=true // Properties that apply once upon window opening. default-column-width { proportion 0.75; } @@ -192,6 +193,23 @@ window-rule { } ``` +#### `at-startup` + +Since: 0.1.6 + +Can be `true` or `false`. +Matches during the first 60 seconds after starting niri. + +This is useful for properties like `open-on-output` which you may want to apply only right after starting niri. + +``` +// Open windows on the HDMI-A-1 monitor at niri startup, but not afterwards. +window-rule { + match at-startup=true + open-on-output "HDMI-A-1" +} +``` + ### Window Opening Properties These properties apply once, when a window first opens. -- cgit