micro/internal
Dmytro Maluka 9eb8782ff2
Rework FindMatchingBrace() interface and implementation (#3319)
Instead of passing a single brace pair to FindMatchingBrace(), make it
traverse all brace pairs in buffer.BracePairs on its own.

This has the following advantages:

1. Makes FindMatchingBrace() easier to use, in particular much easier
   to use from Lua.

2. Lets FindMatchingBrace() ensure that we use just one matching brace -
   the higher-priority one. This fixes the following issues:

    ([foo]bar)
     ^

when the cursor is on `[`:

- Both `[]` and `()` pairs are highlighted, whereas the expected
  behavior is that only one pair is highlighted - the one that the
  JumpToMatchingBrace action would jump to.

- JumpToMatchingBrace action incorrectly jumps to `)` instead of
  `]` (which should take higher priority in this case).

In contrast, with `((foo)bar)` it works correctly.
2024-06-05 00:56:19 +02:00
..
action Rework FindMatchingBrace() interface and implementation (#3319) 2024-06-05 00:56:19 +02:00
buffer Rework FindMatchingBrace() interface and implementation (#3319) 2024-06-05 00:56:19 +02:00
clipboard Use zyedidia/clipper for external clipboard 2022-06-14 08:40:57 -04:00
config Temporarily don't initialize runtime files in buffer test 2024-04-03 04:37:44 +02:00
display Rework FindMatchingBrace() interface and implementation (#3319) 2024-06-05 00:56:19 +02:00
info Reordered prompt done callback to avoid accessing out of bound history (#3318) 2024-06-02 20:00:13 +02:00
lua Revert "Don't expose Go timers directly to lua" (#3211) 2024-03-25 17:11:12 +01:00
screen Reset mouse release state after restarting the screen 2023-01-29 18:26:55 +01:00
shell Fix term output capturing 2023-09-08 23:27:39 -07:00
util Implemented SubWordRight, SubWordLeft, SelectSubWordRight, SelectSubWordLeft and DeleteSubWordRight, DeleteSubWordLeft 2024-05-20 23:23:33 +02:00
views chore: fix some typos (#3239) 2024-04-08 12:04:38 +02:00