Sublime Forum

Code Folding Question

#1

I love the Code Folding feature in ST2. I current use it a lot in my javascript code. I am a long time E Text Edit user and in E, when you folded level 2 and then folded level 1 and then unfolded the same level 1, its level 2 would remain folded. This does not appear to be the case in ST2.

Now for my questions.

  1. Is there a way to fold level 2 of a specific level 1 and not all level 1’s? I may have a level 3 of level 1A unfolded and want to fold all level 2’s of level 1B. Once I do the Ctrl K Ctrl 2, it folds all level 2’s of all level 1’s, which messes up my level 3 unfold on level 1A. I hope that makes sense.

  2. Is there a way to keep the level 2 folded when I then fold its level 1 and then unfold the same level 1? Each time I fold a parent of a child, the childs fold gets undone.

Thanks for any help.

Brent

0 Likes

#2

Gonna hijack this topic.

So my question: if i fold/unfold (z,c / z, o | or just using the default shortcut) ST is not just folds/unfolds the code region but also selects it, which is kinda annoying to me. Is there a way to turn this behavior off?

0 Likes