XCODE 13 Brace matching / Code Collapsing

In XCODE 13, if I select a brace (parenthesis, bracket or brace), the matching brace briefly highlights. This is fine if the matching brace is on the screen, but the highlighting goes away before I can scroll to a matching brace if it is off the screen. Is there a way to find a matching brace that is many lines away? Is there an automatic was to highlight all the code between matching braces?

Secondly, does XCODE have the capability of collapsing code between braces?

Thanks, Mark

When I double click on a curly bracket for instance, all the code between opening and closing curly brackets gets selected, highlighted. It even jumps to the opposite end.

To collapse code, just click in the gutter.

I highlighted in red the gutter area:

  • Hover mouse over the gutter
  • It will turn white
  • Click there, code will collapse

  • Click again to expand.
XCODE 13 Brace matching / Code Collapsing
 
 
Q