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.

Bug 113169 - String breaking cursor to wrong position
Summary: String breaking cursor to wrong position
Status: RESOLVED DUPLICATE of bug 112241
Alias: None
Product: java
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: PC Linux
: P3 blocker (vote)
Assignee: Jan Lahoda
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2007-08-20 06:11 UTC by noot
Modified: 2007-08-24 16:05 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Editor Indention settings (23.27 KB, image/png)
2007-08-21 02:38 UTC, noot
Details
Java Code Formatting Settings (27.61 KB, image/png)
2007-08-21 02:39 UTC, noot
Details

Note You need to log in before you can comment on or make changes to this bug.
Description noot 2007-08-20 06:11:14 UTC
When breaking a string the cursor is placed at the start of the next line instead inside the double quotes on the new line.

Example. After pressing enter inside the string of the first line the second line with quotes is automatically generated
and the cursor is placed at position 2 of the next line. The position should be inside the newly created quotes on the
new line.

String readQuery = "SELECT * " +
 |  "";
 ^cursor
Comment 1 Vitezslav Stejskal 2007-08-20 19:48:04 UTC
It seems to be working fine for me in a dev build. What are your indentation settings (ie. Tools-Options -> Editor ->
Indentation and T-O -> Java Code -> Formatting -> Indents)? Thanks.
Comment 2 noot 2007-08-21 02:37:39 UTC
I'm running Dev 200708171200 btw
Please see the attached files for the settings.
Comment 3 noot 2007-08-21 02:38:37 UTC
Created attachment 46937 [details]
Editor Indention settings
Comment 4 noot 2007-08-21 02:39:22 UTC
Created attachment 46938 [details]
Java Code Formatting Settings
Comment 5 Vitezslav Stejskal 2007-08-21 12:13:29 UTC
Interesting, it's reproducible in today's build. Maybe there was something with my userdir, but here is what I did today:

1. fire up a new build with fresh testuserdir
2. open an old java project
3. create a new java class NewClass
4. create a method and type noot's sample code in it
5. when pressing enter inside the string the caret is not positioned properly, exactly as reported
Comment 6 noot 2007-08-22 02:37:55 UTC
I also did not import settings from my old Netbeans (5.0) user data and the projects are also created by the 5.0
Netbeans version.
Comment 7 Jan Lahoda 2007-08-24 16:05:39 UTC

*** This issue has been marked as a duplicate of 112241 ***