1. Open a file in the editor
2. Collapse some folds
3. Shut down NetBeans
4. Start NetBeans
5. The stuff you have manually folded is unfolded again
IMHO the opened editor should remember the state with respect to collapsed folds. The question is whether the state should be persisted also for closed files (??).
IntelliJ and Eclipse do NOT persist the fold state so maybe I am just crazy to request it.
Would be good to have an option in the Options window specifying whether you want to persist code folds across restarts.
*** Bug 41232 has been marked as a duplicate of this bug. ***
*** Bug 216377 has been marked as a duplicate of this bug. ***
*** Bug 226145 has been marked as a duplicate of this bug. ***
*** Bug 241152 has been marked as a duplicate of this bug. ***
any news about this?
*** Bug 241038 has been marked as a duplicate of this bug. ***
I'd go as far to say that without this enhancement, code folding is a pretty useless feature. I'd like to collapse my accessors and equivalents, but I'm certainly not going to bother doing it every time I open a file.
There are options to have certain constructions auto-collapsed, but accessors not (yet) recognized as special type of methods. Actually implementng accessor auto-collapse option is probably far easier than persistng fold states :)
wow 5 years with this simple feature request and nothing.. Switching IDE is the only option I have now.
(In reply to mkotsollaris from comment #11)
> wow 5 years with this simple feature request and nothing.. Switching IDE is
> the only option I have now.
Persisting code folds is not that trivial. How would you record identity of the non-default fold ? Line or position is bad: text may change as a result of e.g. VCS operation. Then we are talking about remembering some signatures, tree paths (i.e. in PHP, which allows to collapse ifs) etc.
There are still far more important productivity features to implement in the IDE.
Thank you for the explanation, Svata. It makes sense. This is not a "simple" request.
And mkotsollaris, don't make me laugh. Persistent code folding is not a killer feature, and if it's so simple and important to you, you should implement it yourself -- the software is free, after all.
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.
Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss
*** Bug 177864 has been marked as a duplicate of this bug. ***