Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does NetBeans have any "collapse all" shortcut for open directories in the navigator view? [duplicate]

Tags:

NetBeans has a helpful (to me anyway!) feature under the "Views" menu, called "Synchronize Editor with Views". As the name suggests, toggling this on will cause the navigator view to jump straight to a file when it's opened in the editor.

I generally prefer this to the normal "Ctrl+Shift+1" shortcut for manually jumping to a file. However, the downside is that after editing several files, your navigator tree is a mess of multiple open directories.

Eclipse has similar functionality, but it also has a "collapse all" button at the top of its navigator view... restoring things with a single click having to scroll around. Does NetBeans have any similar mechanism for collapsing open directories? Maybe a poorly-documented keyboard shortcut buried in there or something?

like image 650
Steve Perkins Avatar asked Oct 22 '10 20:10

Steve Perkins


People also ask

How do I collapse code in NetBeans?

As shown in the servlet example and as described in Custom Code Folding in NetBeans, one can add custom code folding in NetBeans simply be enclosing the code to be folded within // <editor-fold> and // </editor-fold> comments.


1 Answers

Taken from http://ui.netbeans.org/docs/ui/code_folding/cf_uispec.html

Collapse Fold       Ctrl+Minus  
Expand Fold         Ctrl+Plus   
Collapse All Folds  Ctrl+Shift+Minus        
Expand All Folds    Ctrl+Shift+Plus     
like image 164
Hardik Avatar answered Nov 02 '22 19:11

Hardik