Commit Graph

2008 Commits

Author SHA1 Message Date
Kovid Goyal
c655ea8946 More work on dnd kitten 2026-04-21 14:06:33 +05:30
Kovid Goyal
d0a6b5eeac Implement writing of MIME data on drop 2026-04-21 13:32:02 +05:30
Kovid Goyal
3d8a2fbb4f Use SIMD base64 everywhere 2026-04-21 11:56:55 +05:30
Kovid Goyal
8b3daa6a50 Fix drop data requests 2026-04-21 08:32:42 +05:30
Kovid Goyal
9a011dea3e More work on DnD kitten 2026-04-21 08:19:22 +05:30
Kovid Goyal
01e453a048 More work on DnD kitten 2026-04-20 20:16:02 +05:30
Kovid Goyal
a899d24b64 More work on DnD kitten 2026-04-20 19:19:51 +05:30
Kovid Goyal
54eab02709 Add tests for drop move events 2026-04-20 11:23:49 +05:30
Kovid Goyal
4c484ca1e8 Highlight current drop action 2026-04-20 09:28:31 +05:30
Kovid Goyal
235425ae85 Allow optionally dropping anywhere 2026-04-20 09:24:33 +05:30
Kovid Goyal
d3b8fd67a0 More work on dnd kitten 2026-04-20 09:16:53 +05:30
Kovid Goyal
fcb260bdfa Sort imports 2026-04-19 21:53:09 +05:30
Kovid Goyal
04fcac72ec Update minimum python to 3.11 from 3.10
3.10 is failing in CI and I cant be arsed to figure out why. It's anyway
a few months from EOL
2026-04-19 21:41:58 +05:30
Kovid Goyal
36e8094afe Make dnd kitten testing infra a bit more robust 2026-04-19 21:00:09 +05:30
Kovid Goyal
0ddbffdf79 Allow mocking remote clients 2026-04-19 20:42:43 +05:30
Kovid Goyal
51b0e9c4ad Work on testing infrastructure for DnD kitten 2026-04-19 20:21:55 +05:30
Kovid Goyal
a3dfe2b55a Make sticky_header default to yes 2026-04-19 12:14:39 +05:30
Kovid Goyal
ed6bdacf44 Merge branch 'pdobrev/diff-sticky-header' of https://github.com/pdobrev/kitty 2026-04-19 12:12:37 +05:30
Petar Dobrev
4f5698a5a2 fix overlap with the next file's header 2026-04-19 09:24:44 +03:00
Kovid Goyal
f3cfbb8fbd ... 2026-04-19 10:45:03 +05:30
Kovid Goyal
df1d9235e8 ... 2026-04-19 10:37:42 +05:30
Kovid Goyal
ef07942c82 More work on dnd kitten 2026-04-19 10:35:29 +05:30
Kovid Goyal
36171d1233 More work on dnd kitten 2026-04-19 10:21:01 +05:30
Petar Dobrev
7729e6e1ae kitten diff: add support for sticky header 2026-04-18 18:26:30 +03:00
Kovid Goyal
c3d1665fa6 run go modernizer 2026-04-16 19:12:31 +05:30
Kovid Goyal
15a6a51a22 Fix RemoteCommand usage with bootstrap.py and bootstrap.sh not exiting after RemoteCommand 2026-04-15 05:37:56 +05:30
Kovid Goyal
a47093a7bf ssh kitten: Fix -o RemoteCommand handling 2026-04-15 05:19:22 +05:30
Kovid Goyal
8697da9e2a Merge branch 'feature/support-ssh-remote-command' of https://github.com/zzhaolei/kitty
Fixes #3988
2026-04-14 12:53:34 +05:30
zhaolei
b86367483f Asynchronously read ssh configuration 2026-04-14 14:29:18 +08:00
Kovid Goyal
bcae760ea7 Skeleton for dnd kitten 2026-04-14 11:20:30 +05:30
zhaolei
9b02a59c4e Add support for RemoteCommand option in kitten ssh 2026-04-14 11:11:51 +08:00
Kovid Goyal
3fe884a29a DRYer 2026-04-10 15:32:27 +05:30
Kovid Goyal
5e158f90a7 Fix some responses from terminal sometimes leaking into shell on after kitten exit
Always do a roundtrip at kitten exit, except for special purpose
kittens. This slows down exit by one round trip time (capped at 2
seconds), however it ensures that we never get terminal response leak.

Fixes #9839
2026-04-10 15:14:38 +05:30
Kevin Lui
be7a010b9c hints: Fix trailing punctuation being included in detected URLs 2026-04-07 22:57:36 -07:00
Daniel M German
640225315a Fix ruff E731: replace lambda assignment with def 2026-04-06 09:54:56 -07:00
Daniel M German
3d89cb267c Add alias and combine support to the command palette
Users who define action_alias or kitten_alias in kitty.conf had no way
to discover or trigger these custom commands from the command palette.
Aliased keybindings were miscategorized (landing in "Miscellaneous"
with no help text), and combine bindings had the same problem.

Changes:

- Resolve aliases via opts.alias_map to get correct action names,
  categories, and help text for aliased keybindings
- Add dedicated "Action aliases" and "Kitten aliases" sections that
  list all user-defined aliases, with bound aliases showing their key
  and unbound aliases browsable as unmapped entries
- Add a "Combined actions" section for combine keybindings
- Make alias names searchable in the Go TUI so users can find
  bindings by typing the alias name
- Fix action column highlight positions to match the scored text,
  preventing visual corruption when searching for alias names

Also refactors collect_keys_data into focused single-responsibility
functions and reduces nesting depth across both Python and Go.
2026-04-06 09:45:39 -07:00
Павел Мешалкин
8ffdf7d7ee feat: add per-mapping --allow-fallback for layout-independent shortcuts
Add --allow-fallback option to the map command that controls shifted
and ascii (alternate_key) fallback for individual key mappings.

For non-Latin keyboard layouts, when the current layout key is
non-ascii (codepoint > 127 and < 0xE000), the alternate_key from
the base layout is used for matching if the mapping opts in via
--allow-fallback=shifted,ascii.

Default kitty bindings use --allow-fallback=shifted,ascii so they
work out of the box with non-Latin layouts. User custom mappings
default to --allow-fallback=shifted (preserving existing shifted_key
behavior without ascii fallback).

--allow-fallback=none disables all fallback for a mapping.

Python side: parse_options_for_map() in options/utils.py handles flag
parsing, ShortcutMapping uses it in __init__. get_shortcut() filters
candidates by per-mapping allow_fallback.

Go side: ParseMap() handles --allow-fallback, KeyAction stores
AllowFallback, ShortcutTracker.Match passes it to matching.
MatchesParsedShortcut defaults to shifted,ascii for hardcoded shortcuts.

Migrated kittens (themes, command_palette, diff, choose_files) to
use ShortcutTracker with configurable map entries.

Tests added for Python (5 test methods) and Go (ParseMap + key matching).
2026-03-25 19:34:13 +03:00
Jack Duvall
c48111d92c Highlight full extent of hint matches, not just the prefix label
Add --hints-text-background-color option (default: auto) that can apply
a background color to the matched text after the hint label. This makes
it more clear exactly which text each hint covers.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 11:23:30 -04:00
Daniel M German
9619571dd3 Command palette: fix gofmt struct field alignment in tests 2026-03-22 17:59:42 -07:00
Daniel M German
6a3fe6ae01 Command palette: word-level search with multi-token cross-column matching
Implement a word-level scoring engine for the command palette that replaces
the previous FZF-based approach. Query tokens are matched against pre-tokenized
words in each column (key, action, category) with exact, prefix, and
edit-distance scoring. Multiple search terms are supported with cross-column
matching — items matching more tokens rank higher. Compound query tokens
containing delimiters (e.g. mouse_selection) are matched as units.

Add comprehensive tests using a Go builder API instead of raw JSON blobs,
covering single-token, multi-token, partial-match, ranking, mouse binding,
and unmapped action scenarios.

Add documentation for the command palette kitten.
2026-03-22 17:28:28 -07:00
Kovid Goyal
eddaaed3e3 Modernize Go code 2026-03-21 08:41:47 +05:30
copilot-swe-agent[bot]
3862ae26cc Fix fuzzy match highlighting in choose_files kitten
Fixes #9693
2026-03-17 14:28:56 +05:30
Kovid Goyal
01a70e06c4 ... 2026-03-12 13:53:41 +05:30
Kovid Goyal
0614f05335 Use new SIMD function for non blank checking 2026-03-12 13:50:35 +05:30
Kovid Goyal
d8af7e2c88 Add an option to control highlighting of moved lines 2026-03-12 12:59:46 +05:30
copilot-swe-agent[bot]
f45345c7a7 Add colorMoved support to kitty diff kitten
Fixes #3241
Fixes #9644
2026-03-12 12:44:21 +05:30
Kovid Goyal
9aa938c6cd Make the error message a bit more clear 2026-03-11 21:13:24 +05:30
Kovid Goyal
50bc3f465e Cleanup previous PR
Also fix ask kitten not setting window title in modes other than choose
2026-03-05 11:19:40 +05:30
Kovid Goyal
d15905c918 Change default word regexp to exclude punctuation 2026-03-04 09:20:53 +05:30
copilot-swe-agent[bot]
1785873835 diff kitten: Use a words based algorithm for intra line changed region highlighting
Fixes #9598
2026-03-04 09:06:37 +05:30