Bug 131725 - RTL paragraphs aligned-left in cross-reference dialog
Summary: RTL paragraphs aligned-left in cross-reference dialog
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected) release
Hardware: All All
: medium normal
Assignee: Not Assigned
: 131726 (view as bug list)
Depends on:
Blocks: RTL-CTL Fields-Cross-Reference
  Show dependency treegraph
Reported: 2020-03-30 22:30 UTC by Eyal Rozenberg
Modified: 2020-05-16 08:59 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:

The cross-ref dialog with RTL content (151.25 KB, image/png)
2020-03-30 22:30 UTC, Eyal Rozenberg
ODT document for reproducing the bug (9.48 KB, application/vnd.oasis.opendocument.text)
2020-05-16 07:28 UTC, Eyal Rozenberg

Note You need to log in before you can comment on or make changes to this bug.
Description Eyal Rozenberg 2020-03-30 22:30:49 UTC
Created attachment 159174 [details]
The cross-ref dialog with RTL content

When you insert a cross-reference, a dialog comes up for selecting what you'll be referring to. I won't comment on the dialog's design in general, only about the list of items of the chosen category (headings, numbered paragraphs etc). This list is presented in plain text - which is ok, but it's directed LTR and aligned left-to-right. It is kept on a single line.

What this means is, that instead of seeing the _beginning_ of the paragraph, or line, or heading, you see its _end_. To see the beginning you need to scroll to the right - but it's a different amount of scrolling for each item, because they're not all aligned at the beginning. That also means you don't see the number except on shorter paragraphs, and for the current item, which also appears at the bottom and is thankfully right-aligned if its in an RTL language.

An example of this in the cross-reference selection dialog is attached.

This is actually a really old issue, probably from before v5, and I'm pretty sure I saw it on Windows too. Right now I'm seeing it with v6.4.0.3 release on Devuan GNU/Linux.
Comment 1 Dieter 2020-03-31 06:20:52 UTC
*** Bug 131726 has been marked as a duplicate of this bug. ***
Comment 2 Dieter 2020-05-15 12:20:03 UTC
Eyal, perhaps you can add a documetn with RTL content. This would make it easier for me to verify the bug. Thanks.
Comment 3 Eyal Rozenberg 2020-05-16 07:28:50 UTC
Created attachment 160887 [details]
ODT document for reproducing the bug

As requested - here's a document with a long numbered paragraph. To reproduce the issue, try inserting a cross-reference to a numbered paragraph and have a look at the selection dialog. Only the end of the text of the first numbered paragraph will be visible.
Comment 4 Dieter 2020-05-16 08:59:22 UTC
I confirm it with

Version: (x64)
Build ID: 99c337d1d3831ce9d2c7dc1cbff713f4ac49d6ac
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: Skia/Raster; VCL: win; 
Locale: en-GB (de_DE); UI: en-GB
Calc: CL