Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode, how to expand all collapsed loops in the source code view?

Tags:

xcode

if you collapse the view of a loop (so that it shows the ellipses ... instead of the lines inside the loop) and you do this for many loops, is there a way to quickly expand all of them back to showing all lines of code again?

like image 335
johnbakers Avatar asked Jun 01 '12 03:06

johnbakers


People also ask

How do I enable code folding in Xcode?

If you want to fold / unfold specific blocks of code, since Xcode 7, you have to enable that. Go to Xcode > Preferences > Text Editing > and check 'Code folding ribbon'.

How do you collapse code in Swift?

Select Fold from menu list. It will fold your code and shows 3 dots, folding/covering entire block. Now, to again unfold your code block, release ⌘ (command) button and click on 3 dots folding a block.


2 Answers

Go to menu-->editor-->Code Folding-->Unfold all

like image 92
Meet Avatar answered Oct 20 '22 01:10

Meet


Command + option + shift + <- for collapse code

Command + option + shift + -> for expand code

like image 22
Luan D Avatar answered Oct 20 '22 02:10

Luan D