From a47babc87d73a82a2f82e4eb3a4725ad8907685a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 12 May 2025 22:22:32 +0530 Subject: [PATCH] Delay import on demand --- kitty/rc/resize_os_window.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/kitty/rc/resize_os_window.py b/kitty/rc/resize_os_window.py index da4dc2ebe..08fddbdbc 100644 --- a/kitty/rc/resize_os_window.py +++ b/kitty/rc/resize_os_window.py @@ -3,8 +3,6 @@ from typing import TYPE_CHECKING -from kitty.fast_data_types import get_os_window_size, layer_shell_config_for_os_window, set_layer_shell_config, toggle_fullscreen, toggle_os_window_visibility - from .base import ( MATCH_WINDOW_OPTION, ArgsType, @@ -98,6 +96,13 @@ using this option means that you will not be notified of failures. } def response_from_kitty(self, boss: Boss, window: Window | None, payload_get: PayloadGetType) -> ResponseType: + from kitty.fast_data_types import ( + get_os_window_size, + layer_shell_config_for_os_window, + set_layer_shell_config, + toggle_fullscreen, + toggle_os_window_visibility, + ) windows = self.windows_for_match_payload(boss, window, payload_get) if windows: ac = payload_get('action')