Anyone out there know of a way to extend the code folding to include more than just comments and functions?
I would absolutely love to be able to fold if statements and loops.
Anyone out there know of a way to extend the code folding to include more than just comments and functions?
I would absolutely love to be able to fold if statements and loops.
+10 !
personally i find that horribly, then you can really just overlook pieces of code… (it makes it really more messy…)
Also java editor also doesn’t have that … Why would that be…
You can make a feature request (or look if there is already on and vote on it)
But it wont becoming anytime soon, for example not in 6.1
I agree with Johan here.
I even don’t like it for comments (I don’t just comment for fun )…
Ah you guys…It must be nice to live in a world where all of your code never takes up more than the height of your screen
I’m certainly not arguing in favor of having foldable code automatically folded when I first view it, which yes, could lead to someone missing it if they weren’t reading carefully, but gee whiz, sometimes when I’m debugging or reviewing large control structures to make sure they have full coverage, it sure would be nice to hide away pieces of code that I’ve identified aren’t immediately important to what I’m trying to accomplish.
I’m also not trying to tell you that you should have to use code folding if it doesn’t fit your style or working. Marcel, you might be interested to know you can turn off code folding in the Preferences for your Eclipse and always see all your comments in all their glory.
All I’m really saying is that some people would probably find this tool incredibly useful.
As for why the Java editor doesn’t have it, I have to assume you only mean in Eclipse, and that’s a very good question. I personally find it incredibly surprising considering the vast number of relatively popular IDEs and text editors that do support this either natively or with a plugin. For example vim, emacs, NetBeans, XCode, Visual Studio, gedit, jEdit, Notepad++, and my personal new favorite Sublime Text, just to name a few…I could probably go on…
Anyways… good call on checking for existing requests, I found (and voted for) one here: https://support.servoy.com/browse/SVY-542
That one is looking for more than just Indentation Folding, but also Token Folding. I don’t personally have a use for Token folding…Indent is enough for me, but hey, who am I say it’s a bad idea
Johan, remind me to buy you a few beers at ServoyWorld so we can argue about this like proper geeks.
It would be nice if it could be done along the lines of Visual Studio C#, i.e. you can selectively collapse any section of code by wrapping it in #region / #endregion .
jgarfield:
All I’m really saying is that some people would probably find this tool incredibly useful.As for why the Java editor doesn’t have it, I have to assume you only mean in Eclipse, and that’s a very good question. I personally find it incredibly surprising considering the vast number of relatively popular IDEs and text editors that do support this either natively or with a plugin. For example vim, emacs, NetBeans, XCode, Visual Studio, gedit, jEdit, Notepad++, and my personal new favorite Sublime Text, just to name a few…I could probably go on…
Going on…Ace example: http://ace.ajax.org/build/kitchen-sink.html
jgarfield:
Anyways… good call on checking for existing requests, I found (and voted for) one here: https://support.servoy.com/browse/SVY-542
Voted +1.
Use it all the time in other languages and editors (like BBEdit, 20 years old and still going STRONG).
I personally enjoy wearing out my down arrow keys after lining up my cursor with an IF to find the appropriate ELSE further on down the screen. Personal preference I guess.
why don’t you just double click just besides the { ?
jcompagner:
why don’t you just double click just besides the { ?
(just inside the bracket section) who knew that!
great, thanks!
Rafi