190 Commits

Author SHA1 Message Date
Kovid Goyal
6d826c37b9 More work on floats 2025-04-19 08:15:53 +05:30
Kovid Goyal
56b49c49fb ... 2025-03-28 11:49:47 +05:30
Kovid Goyal
96d5c9c7c6 A new option to clear selections when they no longer reflect the contents of the clipboard 2025-03-12 11:41:27 +05:30
George Joseph
d2288ee787 Add support for os_window_name in startup sessions.
You can now specify `os_window_name` in addition to `os_window_class` in
startup sessions.  It works for the initial session as well as new sessions
started with `new_os_window`.

Updated documentation in overview.rst to add `os_window_name` in the
Startup Session examples.

Although not related to this feature. The documentation in launch.py
was updated to note that the `launch --type` `tab` and `os-window` options
aren't supported when launch is invoked from a startup script.  There's
already a note to that effect in the "Startup Sessions" section in
overview.rst but if you're looking at the launch syntax page like I was,
you wouldn't realize the limitation. This was throwing me for a loop while
wotking on this PR.

Resolves: #8387
2025-03-02 14:10:17 -07:00
Kovid Goyal
f55704c50d launch --next-to should control OS window selection for --type=tab 2025-02-08 08:42:48 +05:30
Kovid Goyal
244f4597dc launch: Decouple source and dest windows from active window
Fixes #8295
2025-02-07 13:40:44 +05:30
Kovid Goyal
da1626090a Update codebase to Python 3.10 using pyupgrade 2025-02-03 10:56:50 +05:30
Koichi Murase
e495aa02f3 clone-in-kitty: Exclude more environment variables from clone target 2025-01-30 16:18:47 +09:00
Kovid Goyal
ea9afc6e89 watchers: Add a new event on_color_scheme_preference_change
Fixes #8246
2025-01-23 05:36:25 +05:30
Kovid Goyal
5a99f3b6cf clone-in-kitty: Fix KITTY_WINDOW_ID being cloned and thus having incorrect value
Fixes #8161
2024-12-25 18:27:40 +05:30
Kovid Goyal
3bee1857f7 Make mypy happy 2024-12-21 08:06:29 +05:30
Kovid Goyal
36074eabc8 Make code to parse color specs and patch options objects re-useable 2024-11-07 13:14:33 +05:30
Kovid Goyal
27cf969a64 Proper error output 2024-11-07 09:35:26 +05:30
Kovid Goyal
6ad9f6fd40 ... 2024-11-07 09:34:10 +05:30
Kovid Goyal
c3c63d3a1e Add a load event for watchers 2024-11-07 09:31:26 +05:30
Kovid Goyal
c1fb18a6ef Implement changing transparent background colors via remote control 2024-09-24 19:02:13 +05:30
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
5ab484cac2 Implement --bias for the grid layout 2024-07-20 13:11:06 +05:30
Kovid Goyal
92385f6db7 Make function re-useable and simplify bias docs a bit 2024-07-20 12:44:46 +05:30
Kovid Goyal
681048f1ca launch command: A new --bias option to adjust the size of newly created windows declaratively
Still need to implement it for the Grid layout.
Fixes #7634
2024-07-20 12:37:18 +05:30
Amos Bird
048ef3b317 Support --env argument for @ run 2024-05-14 22:23:36 +08:00
Kovid Goyal
38fed8b391 kitten @ run: A new remote control command to run a process on the machine kitty is running on and get its output
Fixes #7429
2024-05-14 14:32:01 +05:30
Kovid Goyal
46fed6ffa9 Make remote_control_passwrods parsing code re-useable 2024-05-14 09:28:55 +05:30
Kovid Goyal
54548931b5 Allow running mappable actions via remote control
Saves me having to define a special remote control wrapper for every
mappable action.
2024-02-10 13:23:06 +05:30
Kovid Goyal
e656a75d5e Move implementation of --hold into Child
DRYer. Also fixed use of --hold with launch --cwd=current
2024-01-06 13:14:48 +05:30
Jin Liu
0f52b69372 launch watcher: add on_cmd_startstop event 2023-11-14 16:46:46 +08:00
Kovid Goyal
5ea9700c82 More kitty @ -> kitten @ 2023-10-18 20:40:39 +05:30
Kovid Goyal
314fe4fe4a Allow launched background process to work with --allow-remote-control
Use a dedicated socketpair for such processes. Fixes #6712
2023-10-18 19:56:58 +05:30
Kovid Goyal
81b032a161 Dont expand cwd=current in rc launch
This is easily done at the command line. And its semantics are
are to refer to cwd of active window.
2023-10-17 05:01:28 +05:30
Kovid Goyal
ddb121b418 Remote control launch: Fix the --copy-env option not copying current environment variables
Fixes #6724
2023-10-16 22:32:51 +05:30
Kovid Goyal
537475d5bb Better fix for clone-in-kitty 2023-09-24 11:34:32 +05:30
Kovid Goyal
8e7b6ad3c3 Fix clone-in-kitty broken because of login wrapping 2023-09-24 11:21:32 +05:30
Kovid Goyal
70110d54b0 Use resolved shell for --hold 2023-09-24 08:34:08 +05:30
Kovid Goyal
950fbfbd73 Sanitize user vars 2023-07-27 19:00:21 +05:30
Kovid Goyal
83f423dbb0 Allow specifying user vars with the launch command 2023-07-27 17:44:37 +05:30
Kovid Goyal
0fb1f17af9 Have --hold wait at a shell prompt 2023-06-26 11:21:57 +05:30
Kovid Goyal
474244268c edit-in-kitty: Fix running edit-in-kitty with elevated privileges to edit a restricted file not working 2023-05-07 09:36:16 +05:30
Kovid Goyal
eab3b2a689 Reduce the number of spurious focus events
1) When performing operations known to cause lots of focus changes such
   as creating new sessions/windows or moving windows, forcibly ignore focus events

2) Track window focus state and dont report focus events when the state
   is unchanged by a focus_changed() call

This allows focus specific code to be restricted to just 2-3 places
instead of having to track every possible function that could change
focus.

Fixes #6083
2023-03-02 13:30:26 +05:30
Kovid Goyal
de188faf55 Fix #6048 2023-02-22 19:51:33 +05:30
pagedown
ba83ce7b10 macOS: Display the newly created OS window in specified state
Fix the maximized window can't occupy full screen space when window
decoration or title bar is hidden.
Fix resize_in_steps being applied even when window is maximized.
Allows to specify `os_window_state` in startup session file.
2023-02-18 14:02:19 +08:00
Kovid Goyal
72b2ba51df launch: Allow specifying the state (fullscreen/maximized/minimized) for newly created OS Windows
Fixes #6026
2023-02-16 16:24:46 +05:30
Kovid Goyal
7c8c7fe3a2 launch: When using --cwd=current for a remote system support running non shell commands as well 2023-02-08 17:52:28 +05:30
pagedown
e27920527c Docs: Remove the text role target that is no longer needed 2023-02-01 19:26:38 +08:00
Kovid Goyal
54b6344985 Add a note that --spacing is ignored for overlay windows 2023-01-30 12:00:41 +05:30
Kovid Goyal
6b8e5ea225 Rename kitty-tool to kitten
It's easier to type, and cuter.

Also, most, if not all of the TUI parts of
kitty's kittens will eventually be re-written into kitten.

The only downside I can see is that we cant tab complete kitty
anymore, but hopefully there will be less reason to run kitty
from the shell as command line tools migrate to kitten.

Meowrrrr!!!
2023-01-14 15:44:52 +05:30
Kovid Goyal
7fe5d7b58f Replace isort with ruff 2023-01-09 16:47:42 +05:30
Kovid Goyal
eeb772ad07 @launch: When an overlay window is specified in a particular tab via --match use the active window of that tab as the base, not the current tab. Fixes #5768 2022-12-13 20:15:21 +05:30
Kovid Goyal
f5d2c35755 Move implementation of +hold to Go
No need to pay python interpreter startup cost for --hold
2022-12-01 22:34:56 +05:30
Kovid Goyal
51bba9110e Bash integration: Fix clone-in-kitty not working on bash >= 5.2 if environment variable values contain newlines or other special characters
Bash >= 5.2 changed the export command to output values using $' escaping when they contain special characters.
Fixes #5629
2022-11-22 16:38:24 +05:30
Kovid Goyal
0af48a4d05 Start work on implementing edit-in-kitty in kitty-tool 2022-11-17 17:05:25 +05:30