Bug 382674 - Wrong arrow key navigation in a file with Hebrew text
Summary: Wrong arrow key navigation in a file with Hebrew text
Status: RESOLVED NOT A BUG
Alias: None
Product: kate
Classification: Applications
Component: part (other bugs)
Version First Reported In: 16.08
Platform: Debian stable Linux
: NOR minor
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-24 18:45 UTC by Victor Porton
Modified: 2017-09-27 19:33 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
The file which triggers the error (141 bytes, text/plain)
2017-07-24 18:45 UTC, Victor Porton
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Victor Porton 2017-07-24 18:45:22 UTC
Open the attached file error.txt.

With mouse put the cursor at the rightmost position at the second line of the file.

Press arrow key Right a few times. This causes the cursor jump to the rightmost position of the first line and back.

It is not logical that the cursor is moved by the same arrow key in different directions.

I think, the bug is related to Hebrew characters in the fie.

Kate 16.08.3.
Comment 1 Victor Porton 2017-07-24 18:45:53 UTC
Created attachment 106839 [details]
The file which triggers the error
Comment 2 Safa Alfulaij 2017-09-03 08:39:51 UTC
For me this looks much logical for myself than not logical.
When you are at the end of the first LTR line, you press → arrow to go to the next paragraph.
And when you are at the beginnning of the second RTL line, you press → to go the the prvious paragraph.
I think this is the “visual” way (technically speaking) of how cursor works in input widgets. It's used in normal Qt's QTextEdit widgets (multiline text input widgets) and in gEdit as well.
Comment 3 Dominik Haumann 2017-09-06 11:52:14 UTC
It behaves exactly the same in Qt text edits, so either this is a bug in general in Qt, or indeed the expected behavior. What's the consensus here?
Comment 4 Safa Alfulaij 2017-09-06 12:09:18 UTC
I've checked Glade (Gtk UI designer) and it's the exact same behaviour as Kate, Qt and gEdit.
I'd close this as invalid.
Comment 5 Christoph Feck 2017-09-25 20:38:25 UTC
Victor, users of RTL (right-to-left) languages expect this behaviour, so I am closing this ticket as suggested by previous comments.
Comment 6 Safa Alfulaij 2017-09-27 19:33:28 UTC
I actually found one thing that could make navigating by arrow keys uncomfertable.
It's if an Arabic text file (all lines are rtl) has some empty lines in it (or you added some empty lines), where pressing left arrow will take you to the new line, and left again to the previous RTL line.
I don't know how could this be solved, but it's nice to be more smart in these cases.
I'll ask someone, he might have a nice logical useful idea.