Bug 79585 - RTL: RTL Layout Problem in Impress
Summary: RTL: RTL Layout Problem in Impress
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All Linux (All)
: high normal
Assignee: Not Assigned
URL:
Whiteboard: BSA
Keywords:
Depends on:
Blocks: RTL-CTL
  Show dependency treegraph
 
Reported: 2014-06-03 11:09 UTC by Gil Shwartz
Modified: 2018-09-30 15:36 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
2 sets of 3 strings having mixed English and Hebrew, starting with LTR or RTL character or mark in LTR or RTL paragraph. (41.16 KB, application/vnd.oasis.opendocument.presentation)
2014-06-03 11:09 UTC, Gil Shwartz
Details
Correct formatting of the same text in Writer (26.52 KB, application/vnd.oasis.opendocument.text)
2014-06-03 11:12 UTC, Gil Shwartz
Details
ODT vs ODP (172.73 KB, image/png)
2014-10-31 22:25 UTC, Yousuf Philips (jay) (retired)
Details
Marking of additional differences (191.34 KB, image/jpeg)
2015-12-20 17:27 UTC, Gil Shwartz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gil Shwartz 2014-06-03 11:09:29 UTC
Created attachment 100351 [details]
2 sets of 3 strings having mixed English and Hebrew, starting with LTR or RTL character or mark in LTR or RTL paragraph.

Unlike the correct RTL layout in Writer, the layout of RTL in Impress when the paragraph is RTL is wrong and depend of the first character of the paragraph. Specifically, the location of spaces and punctuation in the text is wrong.

Steps to reproduce:
1. Enter Impress and click on the RTL paragraph button.
2. Write some mixed RTL and LTR text and punctuation starting once with a RTL mark and a second time with a LTR mark.
3. Observe the layout being different depending of the type of mark, which is wrong.

Current behavior:
The type (LTR or RTL) of the first character in the paragraph should not influence on the text formatting in a RTL paragraph, the same way is does not influence it in a LTR paragraph.

Expected behavior:
Identical for the formatting of the same text in Writer, which layouts RTL paragraphs just fine.
Operating System: Ubuntu
Version: 4.2.4.2 release
Comment 1 Gil Shwartz 2014-06-03 11:12:09 UTC
Created attachment 100352 [details]
Correct formatting of the same text in Writer

This file contains the exact same text as the one in the Impress file, showing a correct layout of text in RTL paragraph. It can be used as a reference for correct behavior.
Comment 2 Gil Shwartz 2014-06-03 11:14:37 UTC
Comment on attachment 100351 [details]
2 sets of 3 strings having mixed English and Hebrew, starting with LTR or RTL character or mark in LTR or RTL paragraph.

This is an example of wrong RTL paragraph layout in Impress. The lines having a wrong layout are highlighted with purple text. The correct layout is show in the Writer attachment, where the corresponding line have a yellow background.
Comment 3 Buovjaga 2014-10-31 22:10:44 UTC
For me, using Win 7 64-bit 4.3.3.2, the Writer and Impress "highlighted lines" look equally fine.
As this seems nuanced, I am hesitant to close as WORKSFORME, so I am requesting a retest with 4.3.x.
Files won't open with 4.4 alpha, will file a new bug about that.
Comment 4 Yousuf Philips (jay) (retired) 2014-10-31 22:21:27 UTC
Hello Gil Shwartz,

Thank you for submitting the bug. I can confirm that the bug is available in master on Linux.

Version: 4.4.0.0.alpha1+
Build ID: 3efc3cc5b0b4b6151e928c2348c7dc6f74181db5
TinderBox: Linux-rpm_deb-x86@45-TDF, Branch:master, Time: 2014-10-29_01:36:59
Comment 5 Yousuf Philips (jay) (retired) 2014-10-31 22:25:44 UTC
Created attachment 108746 [details]
ODT vs ODP

I've highlighted in red, the areas where there is difference between the odt and odp.
Comment 6 Buovjaga 2014-10-31 22:33:19 UTC
(In reply to Jay Philips from comment #5)
> Created attachment 108746 [details]
> ODT vs ODP
> 
> I've highlighted in red, the areas where there is difference between the odt
> and odp.

Jay, thanks for the screenie. I can confirm that on Windows those problems you highlighted are not present, so maybe this is Linux-only.
Comment 7 Gil Shwartz 2014-10-31 22:44:43 UTC
For those interested, an interim workaround for this bug is to force the first character of the lines with the wrong ODP formatting to be a RTL Mark (Insert -> Formatting Mark -> Right-to-left mark).
Comment 8 Urmas 2014-11-01 00:13:59 UTC
The error with the middle line in the third block still present in 4.4 master.
Comment 9 Buovjaga 2014-11-01 09:34:08 UTC
Argh, my eyes must have been crossed yesterday night.. I noticed I did have one single error using 4.3.3.2 in the last highlighted line: ".abc" instead of ."abc". Yet, I didn't have the " LTR - error as in Jay's screenshot.
Comment 10 QA Administrators 2015-12-20 16:11:38 UTC Comment hidden (obsolete)
Comment 11 Gil Shwartz 2015-12-20 17:27:51 UTC
Created attachment 121444 [details]
Marking of additional differences

This image highlights additional positions of difference between ODT and ODP.
Comment 12 Gil Shwartz 2015-12-30 18:38:11 UTC
Per the request by QA Administrators, I have verified that the bug exists in LO 5.0.4.2 running on Linux Mint 17.2 (based on Ubuntu 14.04).
Comment 13 QA Administrators 2017-01-03 19:57:36 UTC Comment hidden (obsolete)
Comment 14 Gil Shwartz 2017-01-03 20:18:52 UTC
Per request: the bug still exists in LO 5.2.3.2 on Mint 18.1 (based on Ubuntu 16.04).
Comment 15 Omer Zak 2017-11-04 01:57:13 UTC
Still happens in:

Version: 5.4.2.2.0+
Build ID: 1:5.4.2-3~bpo9+1
CPU threads: 8; OS: Linux 4.9; UI render: default; VCL: gtk2; 
Locale: en-US (en_US.utf8); Calc: group

OS: Debian 64bit Stretch (Debian 9.2, with some backported packages)
Comment 16 Mark Hung 2018-03-03 05:32:12 UTC
Please check with latest master build. Possibly fixed with the following commit:

http://cgit.freedesktop.org/libreoffice/core/commit/?id=e85aa0cc8b306c2f5ca6240b99e1704f772dbebb

tdf#60533 invoke ubidi_setPara with correct paraLevel parameter.

It will be available in 6.1.0.
Comment 17 Mark Hung 2018-04-28 12:39:36 UTC
Verify the in:

Version: 6.1.0.0.alpha1
Build ID: cb47f0d320994e001bc38dc2ee9b7d957b15e6ab
CPU threads: 4; OS: Linux 4.13; UI render: default; VCL: gtk2; 
Locale: en-US (en_US.UTF-8); Calc: group
Comment 18 Yousuf Philips (jay) (retired) 2018-05-02 11:19:24 UTC
Confirmed fixed.

Version: 6.1.0.0.alpha1+
Build ID: 3e5e7a6017334e15c1f4a67d484dba06408627bd
CPU threads: 2; OS: Linux 4.4; UI render: default; VCL: gtk2; 
Locale: en-US (en_US.UTF-8); Calc: group
Comment 19 Lior Kaplan 2018-09-30 15:36:22 UTC
Verified fix with 

Version: 6.1.1.2
Build ID: 1:6.1.1-1
CPU threads: 8; OS: Linux 4.16; UI render: default; VCL: gtk3; 
Locale: en-US (en_US.UTF-8); Calc: group threaded