Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Code folding plugin for Eclipse?

Tags:

eclipse

I dislike Eclipse's code folding feature, because the folding state isn't saved when you close the file, like Visual Studio does with its #region directives.

Does anyone know of a plugin which saves the status of the code folding per file, so that when I open it, the code stays folded?

like image 703
Axonn Avatar asked Jul 29 '11 12:07

Axonn


People also ask

How do you fold in eclipse?

To enable code folding, go to the Folding Preferences page, accessible from Window | Preferences | PHP | Editor | Using Code Folding . If Code Folding is enabled, minus signs will appear in the Annotation Bar next to code blocks which can be folded.

Does Eclipse support JSON?

Eclipse Web Developer ToolsIncludes the HTML, CSS, and JSON Editors, and JavaScript Development Tools from the Eclipse Web Tools Platform project, aimed at supporting client-side web development and node.

When enabled for a specific section What do you do the preferences in Java editor folding control?

The Code Folding Preferences page is accessed from Window | Preferences | PHP | Editor | Code Folding . To configure your code folding preferences: Mark the Enable folding checkbox to enable code to be folded.


1 Answers

Try to use: http://code.google.com/p/coffee-bytes/

You have to download the source code, import project into Eclipse and build it. After that Export code as a deployable plug-in for Eclipse. You will have a package for installation.

  1. Install it into Eclipse.
  2. Go To Eclipse Preferences...
  3. Type in search "Folding"
  4. Select Java->Editor->Folding
  5. Select in ComboBox "Coffee Bytes Java Folding"
  6. On General Tab set checkbox - "User Defined Regions"
  7. In User Defined Regions tab - enter #region as a start tag and #endregion as an end tag

In code folding will be available after setting special comments into it:

// #region
... some code ...
// #endregion
like image 112
Oleksandr Kucherenko Avatar answered Oct 07 '22 04:10

Oleksandr Kucherenko