mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-11-21 07:35:08 +00:00
subseq: Score matches with dynamic programming
score_item tried every combination of positions of the needle chars in the item, which is exponential in the length of the query. Typing the full name of a theme like "Solarized Dark Higher Contrast" in the themes kitten froze it for about half a minute. Instead find the best score for each position of each needle char from the best scores for the previous char. The per char scores are added in the same order as before, so the scores are bit for bit identical. When several sets of positions have exactly the same score, the highlighted positions can be different from before.
This commit is contained in:
parent
c7d4eab814
commit
ef1c0fd416
3 changed files with 154 additions and 64 deletions
|
|
@ -213,6 +213,9 @@ Detailed list of changes
|
|||
|
||||
- Vertical tabs: Improve rendering of tabs when using the ``powerline`` :opt:`tab_bar_style`
|
||||
|
||||
- themes and choose fonts kittens: Fix search freezing for many seconds when
|
||||
typing a long query, such as the full name of a theme
|
||||
|
||||
0.49.1 [2026-09-24]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue