Fix @ set-colors for active_tab_foreground

This commit is contained in:
Kovid Goyal 2021-04-26 20:18:50 +05:30
parent 172023afca
commit 162e498347
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 3 additions and 0 deletions

View File

@ -41,6 +41,8 @@ To update |kitty|, :doc:`follow the instructions <binary>`.
- Special case rendering of the few remaining Powerline box drawing chars
(:iss:`3535`)
- Fix ``kitty @ set-colors`` not working for the :opt:`active_tab_foreground`.
0.20.1 [2021-04-19]
----------------------

View File

@ -295,6 +295,7 @@ class TabBar:
def patch_colors(self, spec: Dict[str, Any]) -> None:
if 'active_tab_foreground' in spec:
self.active_fg = (spec['active_tab_foreground'] << 8) | 2
self.draw_data = self.draw_data._replace(active_fg=color_from_int(spec['active_tab_foreground']))
if 'active_tab_background' in spec:
self.active_bg = (spec['active_tab_background'] << 8) | 2
self.draw_data = self.draw_data._replace(active_bg=color_from_int(spec['active_tab_background']))