diff options
| author | Ivan Molodetskikh <yalterz@gmail.com> | 2023-12-27 21:51:42 +0400 |
|---|---|---|
| committer | Ivan Molodetskikh <yalterz@gmail.com> | 2023-12-27 21:51:42 +0400 |
| commit | c21805bf705bd36a6eb7f79039b759e9af79dfcb (patch) | |
| tree | e24213b023c8129320daa782c8b0830ea334d519 /src/layout/focus_ring.rs | |
| parent | bfc24182670a0b3e17f79d66474fd291b7110732 (diff) | |
| download | niri-c21805bf705bd36a6eb7f79039b759e9af79dfcb.tar.gz niri-c21805bf705bd36a6eb7f79039b759e9af79dfcb.tar.bz2 niri-c21805bf705bd36a6eb7f79039b759e9af79dfcb.zip | |
layout: Refactor to support window decorations, add border and fullscreen backdrop
Windows are now wrapped in Tiles, which keep track of window-specific
decorations. Particularly, I implemented a black fullscreen backdrop,
which finally brings fullscreened windows smaller than the screen in
line with how the Wayland protocol says they should lookâcentered in a
black rectangle. I also implemented window borders, which are similar to
the focus ring, but always visible (and hence affect the layout and
sizing).
Diffstat (limited to 'src/layout/focus_ring.rs')
| -rw-r--r-- | src/layout/focus_ring.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/layout/focus_ring.rs b/src/layout/focus_ring.rs index cbcde19c..b5ead3e2 100644 --- a/src/layout/focus_ring.rs +++ b/src/layout/focus_ring.rs @@ -105,4 +105,12 @@ impl FocusRing { rv.into_iter() } + + pub fn width(&self) -> i32 { + self.width + } + + pub fn is_off(&self) -> bool { + self.is_off + } } |
