From 08041415d1906b1da3c53e8542ed01ba7b911b09 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 3 Oct 2022 13:26:55 +0530 Subject: [PATCH] Document the purpose of for_layout --- kitty/tab_bar.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kitty/tab_bar.py b/kitty/tab_bar.py index 8620a4a9d..58080d45d 100644 --- a/kitty/tab_bar.py +++ b/kitty/tab_bar.py @@ -151,6 +151,9 @@ class SupSub: class ExtraData: prev_tab: Optional[TabBarData] = None next_tab: Optional[TabBarData] = None + # true if the draw_tab function is called just for layout. In such cases, + # if drawing is expensive the draw_tab function should avoid drawing and + # just move the cursor to its final position, as if drawing was performed. for_layout: bool = False