Bug 163208 - Text cursor movement gets stuck using up and down arrow keys
Summary: Text cursor movement gets stuck using up and down arrow keys
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Writer-Page-Break Text-Cursor
  Show dependency treegraph
 
Reported: 2024-09-29 20:57 UTC by Hossein
Modified: 2024-09-30 19:15 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
ODT file showing cursor gets stuck in the start of page 2 (12.48 KB, application/vnd.oasis.opendocument.text)
2024-09-29 20:57 UTC, Hossein
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Hossein 2024-09-29 20:57:30 UTC
Created attachment 196788 [details]
ODT file showing cursor gets stuck in the start of page 2

Description:
When moving the text cursor using up and down arrow keys, sometimes the cursor gets stuck. Looking inside the attached example shows that it happens when soft page break is exactly at the actual page break.

Steps to Reproduce:
1. Open attachment
2. Press and hold down to reach end of the document
3. Press up to move back to the top

Actual Results:
The cursor gets stuck in the last page. Note that the cursor should be adjacent to the right side of the document. This should happen when you press and hold down arrow, then press and hold up arrow.

It happens exactly near <text:soft-page-break/> in content.xml, which matches the point where the page breaks.

<text:p text:style-name="P2" loext:marker-style-name="T1">ببببببببببببببببببببب ببب ب ب بببببببببببببببببببب ببببببببب بببببببببببب بببببببب ببببببببببببب ببببببببببببببببب بببببببببببب بببببببببب بببببببب بببببب بببب ببببب ببببب ببببببب <text:span text:style-name="T2">بببببببب ببببب </text:span><text:soft-page-break/><text:span text:style-name="T3">پپ</text:span><text:span text:style-name="T2"> </text:span><text:span text:style-name="T3">پپ</text:span><text:span text:style-name="T2"> </text:span><text:span text:style-name="T3">پ</text:span><text:span text:style-name="T2"> <text:s text:c="2"/>

One other observation is that if you go to the end of first line in the last page and press up, the cursor oscillates between the beginning and the end of this line. 

Expected Results:
The text cursor should move to the top of document when holding the up arrow.

Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 0e955c4b236bcf9e66e7b49cc3ae285f1a4a9e32
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: x11
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: CL threaded
Comment 1 Jonathan Clark 2024-09-30 19:15:48 UTC
Confirmed. Also present in:

Version: 24.2.6.2 (X86_64) / LibreOffice Community
Build ID: 8e9a753d9daaea75c34b417ba1bdf556bf2fc5b3
CPU threads: 32; OS: Linux 6.8; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded


Important note: This bug is sensitive to font metrics. The bug likely will not reproduce with the attached document under font substitution.