1
0
Fork 0
forked from wry/wry

config: add client window criteria

This commit is contained in:
Julian Orth 2025-05-02 23:46:11 +02:00
parent 59f8acdfde
commit 2b5be7fbd9
19 changed files with 205 additions and 14 deletions

View file

@ -1,7 +1,10 @@
//! Tools for inspecting and manipulating windows.
use {
crate::{Axis, Direction, Workspace, client::Client},
crate::{
Axis, Direction, Workspace,
client::{Client, ClientCriterion},
},
serde::{Deserialize, Serialize},
std::ops::Deref,
};
@ -231,6 +234,8 @@ pub enum WindowCriterion<'a> {
Any(&'a [WindowCriterion<'a>]),
/// Matches if an exact number of the contained criteria match.
Exactly(usize, &'a [WindowCriterion<'a>]),
/// Matches if the window's client matches the client criterion.
Client(&'a ClientCriterion<'a>),
}
impl WindowCriterion<'_> {