From 57ba0f4d87deafd6b814e413b1cf38acd72ce38a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 27 Aug 2024 10:39:15 +0530 Subject: [PATCH] Add a note about X11 specificity of preshow_callback --- kitty/utils.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kitty/utils.py b/kitty/utils.py index 4cad3c5da3..3c879b46e6 100644 --- a/kitty/utils.py +++ b/kitty/utils.py @@ -327,6 +327,10 @@ def end_startup_notification(ctx: Optional['StartupCtx']) -> None: class startup_notification_handler: + # WARNING: This only works on X11 on other platforms extra_callback will be called + # after the window is shown, not before, as they do not do two stage window + # creation. + def __init__(self, do_notify: bool = True, startup_id: Optional[str] = None, extra_callback: Optional[Callable[[int], None]] = None): self.do_notify = do_notify self.startup_id = startup_id