pub struct WindowMatcher(pub u64);Expand description
A window matcher.
Tuple Fields§
§0: u64Implementations§
Source§impl WindowMatcher
impl WindowMatcher
Sourcepub fn bind<F: FnMut(MatchedWindow) + 'static>(self, cb: F)
pub fn bind<F: FnMut(MatchedWindow) + 'static>(self, cb: F)
Sets a function to execute when the criterion matches a window.
Replaces any already bound callback.
Sourcepub fn set_auto_focus(self, auto_focus: bool)
pub fn set_auto_focus(self, auto_focus: bool)
Sets whether newly mapped windows that match this matcher get the keyboard focus.
If a window matches any matcher for which this is false, the window will not be automatically focused.
Sourcepub fn set_initial_tile_state(self, tile_state: TileState)
pub fn set_initial_tile_state(self, tile_state: TileState)
Sets whether newly mapped windows that match this matcher are mapped tiling or floating.
If multiple such window matchers match a window, the used tile state is unspecified.
Sourcepub fn set_initial_floating_size(self, width: i32, height: i32)
pub fn set_initial_floating_size(self, width: i32, height: i32)
Sets the size that matched windows have when they are initially mapped floating.
This has no effect on windows that are initially mapped tiled, even if they later become floating.
If multiple such window matchers match a window, the used size is unspecified.
Sourcepub fn set_initial_floating_position(self, x: i32, y: i32)
pub fn set_initial_floating_position(self, x: i32, y: i32)
Sets the position that matched windows have when they are initially mapped floating.
The position is relative to the top-left corner of the output that the window is mapped on and refers to the top-left corner of the window itself, excluding any decorations. It is clamped so that the window remains at least partially visible on that output.
This has no effect on windows that are initially mapped tiled, even if they later become floating.
If multiple such window matchers match a window, the used position is unspecified.