Commit Graph

131 Commits

Author SHA1 Message Date
Kovid Goyal
83f0d6bc1a Have reloading config also reload the custom tab bar python modules 2025-11-13 14:41:46 +05:30
Kovid Goyal
a54f30ab3d Fix incorrect calculation of tab bar margins
Fixes #9154
2025-10-26 08:51:41 +05:30
Kovid Goyal
c7117c2839 Make the os window id available in tab bar drawing 2025-10-24 07:32:36 +05:30
Kovid Goyal
ab4e86dfec Avoid a copy when custom function is not used 2025-08-30 09:03:34 +05:30
Kovid Goyal
1544830307 Allow using a custom python function in tab_title_template
Makes it easier to do complex processing
2025-08-30 09:02:39 +05:30
Kovid Goyal
cbca4d6593 Implement tab_bar_filter
Useful to manage multiple sessions in a single kitty OS Window.
Add some docs to sessions.rst describing this use case.
2025-08-24 12:25:15 +05:30
Kovid Goyal
e176b723f5 When creating a new window/tab with the same cwd as the current window automatically put the newwindow into the same session as the current window 2025-08-23 13:24:48 +05:30
Kovid Goyal
c2a5af19b0 More tab bar geometry adjustments
A couple more places I forgot to change when shifting window boundaries
to be exclusive. Fixes #8921
2025-08-22 11:16:08 +05:30
Kovid Goyal
41488fe8ba Allow showing the currently active session name in the tab bar 2025-08-19 06:49:14 +05:30
Kovid Goyal
d548a6fcf4 rename typing module to avoid conflicts with stdlib typing 2025-04-28 09:20:10 +05:30
Kovid Goyal
ac2b1fbe0b Fix a regression that caused tab bar margins to not be properly blanked when the tab bar is at the bottom
Fixes #8494
2025-03-30 11:10:03 +05:30
Kovid Goyal
d896d7713d Fix #8288 2025-02-05 08:31:36 +05:30
Kovid Goyal
da1626090a Update codebase to Python 3.10 using pyupgrade 2025-02-03 10:56:50 +05:30
Kovid Goyal
d23adce11c User nerd font symbols for progress as they are guaranteed to exist 2025-01-05 08:58:29 +05:30
Kovid Goyal
9b9b313e77 When a program running in kitty reports progress of a task display it as a percentage in the tab title 2025-01-05 08:48:46 +05:30
Kovid Goyal
ee4b89055f Add wcswidth to safe_builtins 2024-10-19 09:00:01 +05:30
Kovid Goyal
d31459b092 tab_title_template allow using the 256 terminal colors for formatting 2024-10-15 11:45:47 +05:30
Greg Hurrell
44e643ae3f feat: don't draw visible tab bar margins if width is 0
Closes: https://github.com/kovidgoyal/kitty/issues/7871
2024-09-19 13:14:17 +02:00
Kovid Goyal
f1d0d0949b Run pyupgrade to update the codebase to python 3.9
Gets rid of a lot of typing ugliness by using type annotations on
builtin types
2024-07-31 07:55:27 +05:30
Kovid Goyal
0cf9a79760 A new option second_transparent_bg
Makes a second background color semi-transparent via background_opacity.
Useful for things like cursor line highlight in editors.

Fixes #7646
2024-07-21 20:22:31 +05:30
Kovid Goyal
23779da2dc Provide access to the current keyboard mode in the tab_title_template 2024-04-01 22:12:49 +05:30
Kovid Goyal
77292a16d6 Make shebangs consistent
Follow PEP 0394 and use /usr/bin/env python so that the python in the
users venv is respected. Not that the kitty python files are meant to be
executed standalone anyway, but, whatever.

Fixes #6810
2023-11-11 08:32:05 +05:30
Kovid Goyal
9a0068e318 Also update ANSI color table for tab bar screen objects 2023-05-14 07:13:49 +05:30
Kovid Goyal
ecfebcd6af ... 2023-03-07 12:42:25 +05:30
Kovid Goyal
cd4b19918c make the latest mypy happy 2023-03-07 12:02:08 +05:30
Kovid Goyal
64fe9f82ed Add chr and ord to safe_builtins 2023-02-11 05:51:24 +05:30
Kovid Goyal
7fe5d7b58f Replace isort with ruff 2023-01-09 16:47:42 +05:30
Kovid Goyal
41207aa830 kitty @ get-colors: Report the current tab bar colors for the active OS window rather than configured values. Fixes #5865 2023-01-07 13:56:36 +05:30
Kovid Goyal
fda4aa21a1 When drawing the tab bar have the default left and right margins drawn in a color matching the neighboring tab
Fixes #5719
2022-12-04 20:51:41 +05:30
Kovid Goyal
7a348d6ef1 Store updated tab bar edge colors on every tab bar redraw 2022-12-04 14:38:56 +05:30
Kovid Goyal
722a1020fa Cleaner implementation of max_tab_title_length
Ensures that tab decorations are not affected
2022-11-29 23:20:39 +05:30
Kovid Goyal
5c50e3869c Change the new option to limit tab title lengths to apply to the length of the title, as documented, nit the full tab 2022-11-29 17:41:27 +05:30
Ferdinand Ratajczak
b6792a6d71 Add option to limit length of tab titles 2022-11-29 09:50:32 +01:00
Kovid Goyal
dd4051bfd5 Allow getting the exe name of the active foreground process in the tab title template 2022-11-17 22:06:06 +05:30
Kovid Goyal
e309e54002 Allow using the re module in tab title templates
Fix #5639
2022-11-01 22:25:58 +05:30
Kovid Goyal
1402c5bbfa Forgot to change check for space for next tab to use its max tab length rather than the current tabs max tab length, since they can now be different 2022-10-03 16:21:50 +05:30
Kovid Goyal
f0f0c8f4fe max_title_length -> max_tab_length 2022-10-03 16:15:24 +05:30
Kovid Goyal
96faac95db DRYer 2022-10-03 15:32:42 +05:30
Kovid Goyal
08041415d1 Document the purpose of for_layout 2022-10-03 13:26:55 +05:30
Kovid Goyal
647b18d345 Tab bar: Improve empty space management when some tabs have short titles, allocate the saved space to the active tab
Fixes #5548
2022-10-03 13:24:21 +05:30
Kovid Goyal
e3a4150fea Second draw attempt has single fade edge 2022-07-29 08:15:38 +05:30
Kovid Goyal
0ce2a23af3 Allow tab title templates to use the current max title length 2022-07-29 07:43:55 +05:30
Kovid Goyal
546cdbefae Don't expose all Tab methods in title template
They can have side effects so prevent user from foot shot
2022-07-26 13:13:00 +05:30
Kovid Goyal
352c07987b Nicer fix for showing cwd in tab titles 2022-07-26 12:35:07 +05:30
Kovid Goyal
f6a1eb19d7 Only import ReferenceType when type checking 2022-07-26 11:06:19 +05:30
Kovid Goyal
c7fa6f620a py3.8 compat 2022-07-26 08:39:33 +05:30
Kovid Goyal
04690c8c7c Dont incur the cost of checking the cwd of a process on every tabbar update unless actually needed 2022-07-26 08:19:14 +05:30
noval
237bfc9a6e add cwd to TabBarData
this option add current working directory to the tab by using active windows child directory.
2022-07-26 09:33:55 +07:00
Kovid Goyal
f95bc48f9b kitty @ set-colors: Fix changing inactive_tab_foreground not working
Fixes #5214
2022-06-19 20:20:58 +05:30
Kovid Goyal
34a0218f35 Fix a regression in the previous release that broke active_tab_foreground
Fixes #4620
2022-02-03 18:12:42 +05:30