This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Many times when I fold a block of code it just expands automatically, I fold it and expands automatically again and this happens again and again and again. This is a big problem while I'm writing code. Please fix this bug.
Can you please provide some useful information about your environment? Go to "Help > About", select the IDE data, copy and paste here. Did you install some 3rd-party plugin from the NetBeans Update Center? Is this Java SE distro, Java EE distro etc.? Can you reproduce this problem if you run NetBeans with an empty userdir (netbeans.exe --userdir C:\empty_userdir)?
Here is IDE data. Product Version: NetBeans IDE 8.0.2 (Build 201411181905) Updates: NetBeans IDE is updated to version NetBeans 8.0.2 Patch 2 Java: 1.8.0_45; Java HotSpot(TM) 64-Bit Server VM 25.45-b02 Runtime: Java(TM) SE Runtime Environment 1.8.0_45-b15 System: Windows 8 version 6.2 running on amd64; Cp1252; en_US (nb) User directory: C:\Users\rafi_\AppData\Roaming\NetBeans\8.0.2 Cache directory: C:\Users\rafi_\AppData\Local\NetBeans\Cache\8.0.2
(In reply to Jiri Kovalsky from comment #1) > Can you please provide some useful information about your environment? Go to > "Help > About", select the IDE data, copy and paste here. > > Did you install some 3rd-party plugin from the NetBeans Update Center? Is > this Java SE distro, Java EE distro etc.? Can you reproduce this problem if > you run NetBeans with an empty userdir (netbeans.exe --userdir > C:\empty_userdir)? Here is IDE data-- Here is IDE data. Product Version: NetBeans IDE 8.0.2 (Build 201411181905) Updates: NetBeans IDE is updated to version NetBeans 8.0.2 Patch 2 Java: 1.8.0_45; Java HotSpot(TM) 64-Bit Server VM 25.45-b02 Runtime: Java(TM) SE Runtime Environment 1.8.0_45-b15 System: Windows 8 version 6.2 running on amd64; Cp1252; en_US (nb) User directory: C:\Users\rafi_\AppData\Roaming\NetBeans\8.0.2 Cache directory: C:\Users\rafi_\AppData\Local\NetBeans\Cache\8.0.2 I am using Netbeans for PHP. I have several third party plugins installed, like Auto save module, Zen coding, CSS preprocessors, GIT etc...
Can you please describe what do you do in editor, before the fold expands? Now the fold should expand only when the cursor should jump inside the collapsed block (e.g. going to bookmark, go to line, stop at breakpoint etc...). Have you tried to start NB without additional modules as Jirka asked? You can try it when you use fresh userdir by specifying the --userdir option. To return back to your current settings just omit the command line switch. http://wiki.netbeans.org/FaqAlternateUserdir
In general, folds in PHP work acceptably, so you must be hitting some specific situation - e.g. start writing right after a folded method or something similar. Please describe the reproduction steps as detailed as possible. If possible provide a sample source file to work with. Not a P1 bug -- no data loss occurs, automatic code folding can be folded off on per-language basis, and you don't need to use manual folds.
(In reply to Jiri Prox from comment #4) > Can you please describe what do you do in editor, before the fold expands? > > Now the fold should expand only when the cursor should jump inside the > collapsed block (e.g. going to bookmark, go to line, stop at breakpoint > etc...). > > Have you tried to start NB without additional modules as Jirka asked? > You can try it when you use fresh userdir by specifying the --userdir > option. To return back to your current settings just omit the command line > switch. > > > http://wiki.netbeans.org/FaqAlternateUserdir I just do nothing, I can't do anything, I fold my code block and i scroll down or up and the code block expands automatically. I will try the --userdir and let you know. (Thanks for your comment)
(In reply to Svata Dedic from comment #5) > In general, folds in PHP work acceptably, so you must be hitting some > specific situation - e.g. start writing right after a folded method or > something similar. Please describe the reproduction steps as detailed as > possible. If possible provide a sample source file to work with. > > Not a P1 bug -- no data loss occurs, automatic code folding can be folded > off on per-language basis, and you don't need to use manual folds. I've tried to find my specific situation, and i myself have tried many things but couldn't find if any other situation is making this auto expanding. Sometimes folding block works for a long time and sometimes not. Meaning, sometimes auto expand doesn't happen immediately, it takes long time (10 min may be).
Created attachment 155599 [details] List of installed plugins
What kind of folded block gets expanded ? function, if-else, ... ? Consistently one type of construction, [various] block statements within a function, or entire functions ? Just one or a few folds, or all collapsed folds (or all within a certain region, i.e. a within a single function - the one being edited) ? Please confirm that folds expand just when scrolling/viewing the code, without any modification to the source.
Discussed offline: XML issue.
(In reply to Svata Dedic from comment #9) > What kind of folded block gets expanded ? function, if-else, ... ? > Consistently one type of construction, [various] block statements within a > function, or entire functions ? Just one or a few folds, or all collapsed > folds (or all within a certain region, i.e. a within a single function - the > one being edited) ? > > Please confirm that folds expand just when scrolling/viewing the code, > without any modification to the source. All kind of folded block gets auto expanded. It even expands if i just do nothing not even scrolling and not even any modification, just nothing...
Disregard my last comment, reassinging back :) sorry for confusion, I've messed two bug numbers.
(In reply to rafi from comment #11) > All kind of folded block gets auto expanded. It even expands if i just do > nothing not even scrolling and not even any modification, just nothing... Did you experience similar folding defect with other files, like (X)html, CSS, JS ?
(In reply to Svata Dedic from comment #13) > (In reply to rafi from comment #11) > > > All kind of folded block gets auto expanded. It even expands if i just do > > nothing not even scrolling and not even any modification, just nothing... > > Did you experience similar folding defect with other files, like (X)html, > CSS, JS ? Good question. Answer is no, it happens only in php files.
Tomasi - any idea how the reported defect may be caused ?
(In reply to Svata Dedic from comment #15) > Tomasi - any idea how the reported defect may be caused ? Ondra knows the editor area, adding him to CC, maybe he will have an idea. Thanks. (BTW this issue has never happened to me personally.)
Moving to PHP for further investigation
I cannot reproduce this issue and since we have no other report similar to this one, it has to be something related to your setup. So: - could you please try a clean userdir [1]? - does it happen for all your PHP files (pure PHP, PHP + HTML) in all your PHP projects? - reproduce your problem and attach here your IDE log file [2] (BTW it is always a good idea to attach your IDE log file, to any reported issue). - perhaps you could also try a development version of NetBeans [3] to verify that this issue is still there. Simply reopen this issue and provide answers/files we asked for. Thanks for your cooperation. [1] http://wiki.netbeans.org/FaqWhatIsUserdir [2] http://wiki.netbeans.org/FaqLogMessagesFile [3] http://bits.netbeans.org/download/trunk/nightly/latest/ Product Version: NetBeans IDE Dev (Build 20150904-e2feafa1bb8a) Java: 1.7.0_80; Java HotSpot(TM) 64-Bit Server VM 24.80-b11 Runtime: Java(TM) SE Runtime Environment 1.7.0_80-b15 System: Linux version 3.19.0-26-generic running on amd64; UTF-8; cs_CZ (nb)
Created attachment 155954 [details] The Log File 1. It happens for files which have PHP and HTML both. 2. I've attached my log file. Thanks for your close inspection bro.
I cannot see anything suspicious in your IDE log. (In reply to Tomas Mysik from comment #18) > - could you please try a clean userdir [1]? > - does it happen for all your PHP files (pure PHP, PHP + HTML) in all your > PHP projects? > - perhaps you could also try a development version of NetBeans [3] to verify > that this issue is still there. > > Simply reopen this issue and provide answers/files we asked for. Thanks for > your cooperation. > [1] http://wiki.netbeans.org/FaqWhatIsUserdir > [3] http://bits.netbeans.org/download/trunk/nightly/latest/ Could you please try/answer also the other things? Thanks.
This was mistakenly closed by some other member.
(In reply to rafi from comment #21) > This was mistakenly closed by some other member. No, it wasn't. You did not respond to our questions, see comment #20. Without that, we are hardly able to help you, sorry. Of course, the best would be if you could provide a sample file and/or project so we can investigate it. Thanks.