[
https://issues.apache.org/jira/browse/NETBEANS-979?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16520920#comment-16520920
]
Eirik Bakke commented on NETBEANS-979:
--------------------------------------
Doing a few more experiments with this, especially comparing to the behavior in
other editors, I think the caret might actually be painted in the correct
position--this should rather be regarded as a bug in the up/down/home/end
actions.
> With line wrap enabled, cursor at end of line is painted at beginning of next
> line instead
> ------------------------------------------------------------------------------------------
>
> Key: NETBEANS-979
> URL: https://issues.apache.org/jira/browse/NETBEANS-979
> Project: NetBeans
> Issue Type: Bug
> Components: editor - Painting & Printing
> Reporter: Eirik Bakke
> Priority: Major
> Fix For: 9.0
>
>
> In an editor with line wrap enabled, the cursor is shown at the wrong
> physical location whenever it is supposed to be located at the end of a wrap
> line. Instead of being painted at the end of the wrap line, it is painted at
> the beginning of the following line. This causes the behavior of keyboard
> shortcuts like "End" and "Up" to seem nonsensical to the user, although they
> might well be behaving correctly wrt. the physical location of the cursor
> (the character offset).
> To reproduce:
> 1) Go to Options/Preferences->Editor->Formatting, select "All Languages" and
> set "Line Wrap" to "After words". Click OK.
> 2) Create a new plain text file and open it in the editor.
> 3) Type some gibberish into the editor on a single line that is long enough
> to be broken into several break lines.
> 4) With the cursor before the first character of the first wrap line in the
> paragraph, press the "End" key (Command+Right on MacBook keyboards). The
> cursor appears to move one line down, which is unexpected. From looking at
> this situation, the user would now assume that they could press the "Up" key
> to move the cursor back to the previous break line, but this will not change
> the cursor position (because the cursor is logically on the previous line).
> 5) Another unexpected example: Pressing Home anywhere in a paragraph will
> move the cursor to the first character on the paragraph rather than at the
> first character of the wrap line. (This might indicate that the problem is
> more than just a paint bug, though.)
> Originally reported in BugZilla at
> https://netbeans.org/bugzilla/show_bug.cgi?id=242115 . Still reproducible on
> NetBeans 9.0 rc2.
> See also https://issues.apache.org/jira/browse/NETBEANS-980 .
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists