Pair brackets

CudaText has built-in pair bracket finder. Before that you needed the plugin Bracket Helper, and now plugin should not be used - it is much slower that built-in code. Bracket finder can highlight pair brackets, when there is only single caret, no selection. It finds symbols "()[]{}<>" (configurable per lexer). Bracket finder respects lexer context, it skips symbols inside syntax comments/strings. If caret is placed not directly on/after a bracket, program will find nearest surrounding brackets.

There are several options:

  • "bracket_highlight"
  • "bracket_symbols" (includes only symbols ()[]{} by default, but you can enable symbols <> for example in HTML lexer specific config)
  • "bracket_distance"
  • "auto_close_brackets"

There are several commands in the Command Palette:

  • brackets: pair highlight: on
  • brackets: pair highlight: off
  • brackets: pair highlight: toggle
  • brackets: jump to pair
  • brackets: select to pair
  • brackets: select to pair, inside (it makes selection smaller by 2 characters)