From f90eb0cbe4ca8f59b9664bac54f8c8b8a0cbd526 Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Sat, 1 Feb 2025 10:46:52 +0300 Subject: Implement tabbed column display mode --- src/layout/workspace.rs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'src/layout/workspace.rs') diff --git a/src/layout/workspace.rs b/src/layout/workspace.rs index 0dca0805..f811b37e 100644 --- a/src/layout/workspace.rs +++ b/src/layout/workspace.rs @@ -577,10 +577,10 @@ impl Workspace { self.floating.add_tile_above(next_to, tile, activate); } else { // FIXME: use static pos - let (next_to_tile, render_pos) = self + let (next_to_tile, render_pos, _visible) = self .scrolling .tiles_with_render_positions() - .find(|(tile, _)| tile.window().id() == next_to) + .find(|(tile, _, _)| tile.window().id() == next_to) .unwrap(); // Position the new tile in the center above the next_to tile. Think a @@ -1022,6 +1022,13 @@ impl Workspace { self.scrolling.swap_window_in_direction(direction); } + pub fn toggle_column_tabbed_display(&mut self) { + if self.floating_is_active.get() { + return; + } + self.scrolling.toggle_column_tabbed_display(); + } + pub fn center_column(&mut self) { if self.floating_is_active.get() { self.floating.center_window(None); @@ -1336,7 +1343,6 @@ impl Workspace { &self, ) -> impl Iterator, Point, bool)> { let scrolling = self.scrolling.tiles_with_render_positions(); - let scrolling = scrolling.map(|(tile, pos)| (tile, pos, true)); let floating = self.floating.tiles_with_render_positions(); let visible = self.is_floating_visible(); -- cgit