From 26ea343f95303217a6b14b3d6214dac0777891dc Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 22 Oct 2025 13:21:53 +0530 Subject: [PATCH] Fix failing tests --- kitty_tests/layout.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/kitty_tests/layout.py b/kitty_tests/layout.py index a1de75581..10c203af9 100644 --- a/kitty_tests/layout.py +++ b/kitty_tests/layout.py @@ -2,6 +2,8 @@ # License: GPL v3 Copyright: 2018, Kovid Goyal from kitty.config import defaults +from kitty.fast_data_types import Region +from kitty.layout.base import lgd from kitty.layout.interface import Grid, Horizontal, Splits, Stack, Tall from kitty.types import WindowGeometry from kitty.window import EdgeWidths @@ -47,6 +49,12 @@ def create_layout(cls, opts=None, border_width=2): ans = cls(1, 1) ans.set_active_window_in_os_window = lambda idx: None ans.swap_windows_in_os_window = lambda a, b: None + orig = ans._set_dimensions + def set_dimensions(all_windows): + orig(all_windows) + # we need a non-zero width and height for central + lgd.central = Region((0, 0, 0, 0, 1, 1)) + ans._set_dimensions = set_dimensions return ans