Download it now!
Bug 58070 - RTL [HE] EDITING Switching paragraph style changes character orientation
Summary: RTL [HE] EDITING Switching paragraph style changes character orientation
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
3.6.2.2 release
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 96859 (view as bug list)
Depends on:
Blocks: RTL-CTL Writer-Styles-Paragraph
  Show dependency treegraph
 
Reported: 2012-12-10 08:07 UTC by Inkbug
Modified: 2020-02-29 10:57 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Downstream attachment (12.50 KB, application/msword)
2013-05-29 11:09 UTC, Christopher M. Penalver
Details
Manifesting document saved as ODT (10.22 KB, application/vnd.oasis.opendocument.text)
2020-02-29 10:52 UTC, Eyal Rozenberg
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Inkbug 2012-12-10 08:07:33 UTC
Steps to reproduce:
1. Create new paragraph
2. Change paragraph direction to RTL
3. Change paragraph style to Heading 1

Current Behavior:
The paragraph becomes a heading but switches back to LTR direction.

Expected Behavior:
The paragraph becomes a heading but stays RTL.
Comment 1 Christopher M. Penalver 2013-05-29 11:09:00 UTC
Created attachment 79954 [details]
Downstream attachment
Comment 2 Christopher M. Penalver 2013-05-29 11:27:54 UTC
As per downstream report https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1093765 :

1) lsb_release -rd
Description: Ubuntu 13.04
Release: 13.04

2) apt-cache policy libreoffice-writer
libreoffice-writer:
  Installed: 1:4.0.2-0ubuntu1
  Candidate: 1:4.0.2-0ubuntu1
  Version table:
 *** 1:4.0.2-0ubuntu1 0
        500 http://archive.ubuntu.com/ubuntu/ raring/main i386 Packages
        100 /var/lib/dpkg/status

3) What is expected to happen in Writer via a terminal:
cd ~/Desktop && wget https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1093765/+attachment/3688368/+files/test-bug1093765.doc && lowriter --nologo test-bug1093765.doc

is select all -> change combo box Apply Style from Text Body to Heading 1 and the text style changes, preserving the character order.

4) What happens instead is:
(Example text=) טקסט לדוגמה

changes to:
טקסט לדוגמה (=Example text)

Microsoft Office Professional Plus 2010 Word Version 14.0.6023.1000 (32-bit) changes it to:
=)טקסט לדוגמהExample text(
Comment 3 QA Administrators 2015-03-04 02:21:25 UTC Comment hidden (obsolete)
Comment 4 Buovjaga 2015-03-22 14:12:31 UTC
(In reply to Inkbug from comment #0)
> Steps to reproduce:
> 1. Create new paragraph
> 2. Change paragraph direction to RTL
> 3. Change paragraph style to Heading 1
> 
> Current Behavior:
> The paragraph becomes a heading but switches back to LTR direction.
> 
> Expected Behavior:
> The paragraph becomes a heading but stays RTL.

Reproduced.

Win 7 Pro 64-bit, LibO Version: 4.4.1.2
Build ID: 45e2de17089c24a1fa810c8f975a7171ba4cd432
Locale: fi_FI
Comment 5 Buovjaga 2016-01-04 11:39:56 UTC
*** Bug 96859 has been marked as a duplicate of this bug. ***
Comment 6 Omer Zak 2017-11-03 01:31:37 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 7 Dina 2018-09-17 19:36:11 UTC
(In reply to Inkbug from comment #0)
> Steps to reproduce:
> 1. Create new paragraph
> 2. Change paragraph direction to RTL
> 3. Change paragraph style to Heading 1
> 
> Current Behavior:
> The paragraph becomes a heading but switches back to LTR direction.
> 
> Expected Behavior:
> The paragraph becomes a heading but stays RTL.

Managed to reproduce it by following your instructions on the "Downstream attachment" file, but not on a new document.

Lubuntu 18.04.1 32bit

LibreOffice Version: 6.1.1.2
Build ID: 1:6.1.1~rc2-0ubuntu0.18.04.1~lo3
CPU threads: 1; OS: Linux 4.15; UI render: default; VCL: gtk2; 
Locale: he-IL (en_US.UTF-8); Calc: group threaded
Comment 8 QA Administrators 2019-10-01 03:02:36 UTC Comment hidden (obsolete)
Comment 9 Eyal Rozenberg 2020-02-29 10:52:24 UTC
Created attachment 158272 [details]
Manifesting document saved as ODT

The bug still manifests if we save attachment 79954 [details] as an ODT rather than a DOC file.
Comment 10 Eyal Rozenberg 2020-02-29 10:57:52 UTC
I am:

* ABLE to reproduce with the original attached DOC document.
* UNABLE to reproduce on a plain new document.
* ABLE to reproduce on the ODT version of the original attachment.

LO Version: 6.4.0.3
Build ID: b0a288ab3d2d4774cb44b62f04d5d28733ac6df8
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: gtk3; 
Locale: he-IL (en_IL); UI-Language: en-US


Now, looking at the saved ODT's XML, we see:

    <office:automatic-styles>
        <style:style style:name="P1" style:family="paragraph" style:parent-style-name="Text_20_body" style:list-style-name="WW8Num2" style:master-page-name="Standard">
            <style:paragraph-properties fo:margin-top="0in" fo:margin-bottom="0.0835in" loext:contextual-spacing="false" fo:text-align="end" style:justify-single-word="false" style:page-number="auto" style:writing-mode="rl-tb" />
        </style:style>

I wonder... perhaps the combination of tags:

fo:text-align="end" style:writing-mode="rl-tb"

is the culprit? That is, perhaps it's treated differently, or scrapped, when LO switch styles, because it's expecting this information elsewhere? Just speculating.