Fold / Collapse the except code section in sublime text 2

前端 未结 5 2172
清酒与你
清酒与你 2020-12-23 00:02

Is there any plugin or shortcut to hide all except code section in sublime text 2?

I need to fold all except section at a time , Not fold one section at a time.

5条回答
  •  庸人自扰
    2020-12-23 00:53

    I know this is an old question, but it still comes up high in search results and none of the answers quite do what the OP wanted.

    1. select the code you don't want to be hidden
    2. use "Selection" -> "Invert Selection" to select the code you do want to be hidden instead
    3. use ctrl + shift + [ or Command + Option + ] to collapse the selection(s)

    This will leave you with just the code you originally had selected visible.

提交回复
热议问题