diff --git a/kitty/layout/base.py b/kitty/layout/base.py index ed1f164ee..e2c3c0144 100644 --- a/kitty/layout/base.py +++ b/kitty/layout/base.py @@ -218,7 +218,7 @@ class Layout: self.remove_all_biases() def bias_increment_for_cell(self, is_horizontal: bool) -> float: - self._set_dimensions() + self.set_dimensions() if is_horizontal: return (lgd.cell_width + 1) / lgd.central.width return (lgd.cell_height + 1) / lgd.central.height @@ -297,11 +297,11 @@ class Layout: is_visible = window is active_window or (is_group_leader and not self.only_active_window_visible) window.set_visible_in_layout(is_visible) - def _set_dimensions(self) -> None: + def set_dimensions(self) -> None: lgd.central, tab_bar, vw, vh, lgd.cell_width, lgd.cell_height = viewport_for_window(self.os_window_id) def __call__(self, all_windows: WindowList) -> None: - self._set_dimensions() + self.set_dimensions() self.update_visibility(all_windows) self.blank_rects = [] self.do_layout(all_windows) diff --git a/kitty/tabs.py b/kitty/tabs.py index 97501d523..b19d3f509 100644 --- a/kitty/tabs.py +++ b/kitty/tabs.py @@ -204,6 +204,7 @@ class Tab: # {{{ if tm is not None: w = self.active_window ly = self.current_layout + ly.set_dimensions() self.borders( all_windows=self.windows, current_layout=ly, extra_blank_rects=tm.blank_rects,