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.
Create new web application Delete all content of the index.jsp and paste content of the attatched file into editor set the cursor possition to 21:54 "<% if (true){|" press Enter cursor possition is always on 22:13 not acording to the indentation of "if"
Created attachment 31758 [details] source code that invoke wrong code indentation
Created attachment 31759 [details] snap shot
Fixed together with issue 79366.
Scriptlets indentaion still doesn't work well use this code: <% if(true){ switch(age){ case 10: a=b;| } } %> press enter at the possition of "|" and continue writing for example with case 20: c=d; default: sayHallo(); code is indented like this: <% if(true){ switch(age){ case 10: a=b; case 20: c=d; default: sayHallo(); } } %>
removing the fix-in-55 tag: a regression; bad user experience, upgrading to P2.
Problems with new line indent in the switch statement are still reproducible, although the behavior is slightly different now - the caret returns to column 0 (which is probably better for us). We still rely on the old, unsupported java infrastructure for new line indent in the scriptlets. An embedding-friendly JavaIndentTask will not be implemented in 6.0.
I belive the case reformat in java works because they "listen" on : char and invoke some indentation code when user types the char behind case. I'll look at the java implementation, maybe it is easy to enable in JSP. Adding fix-in-60 just to remind myself to look at the issue, I'll turn the issue back to future if it is hard to fix.
Tome, can you please reevaluete this one? Thanks
moving opened issues from TM <= 6.1 to TM=Dev
The first example (pos 21:54) works for me. The second example (switch statement) does not work ("smart enter" does not work). Tested with NB 6.5 (Build 080808).
Another Java formatter issue. Mila, Dusan, let us know if you need something from JSP/HTML formatter.
Product Version: NetBeans IDE Dev (Build 200909071948) Java: 1.5.0_20; Java HotSpot(TM) Client VM 1.5.0_20-141 System: Mac OS X version 10.5.8 running on i386; MacRoman; en_US (nb) First case works, but the second one doesn't.
To solve the second problem, JspJavaIndentTask should be rewritten to the new Editor Indentation SPI.
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