Bug 95175 - Impress: can't change text alignment in text frame of specific ODP via Paragraph (can via Text Anchor or Clear Formatting)
Summary: Impress: can't change text alignment in text frame of specific ODP via Paragr...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
3.5.0 release
Hardware: All All
: lowest minor
Assignee: Not Assigned
URL: https://help.libreoffice.org/6.4/en-U...
Whiteboard:
Keywords: filter:odp
Depends on:
Blocks: Textbox
  Show dependency treegraph
 
Reported: 2015-10-19 10:55 UTC by Tomislav Nakic-Alfirevic
Modified: 2023-05-14 18:40 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
broken alignment in the "can't right-align" text box (20.43 KB, application/vnd.oasis.opendocument.presentation)
2015-10-19 10:55 UTC, Tomislav Nakic-Alfirevic
Details
Forat->Align menu bug (403.98 KB, image/png)
2021-11-18 16:40 UTC, Tomislav Nakic-Alfirevic
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tomislav Nakic-Alfirevic 2015-10-19 10:55:10 UTC
Created attachment 119743 [details]
broken alignment in the "can't right-align" text box

Observed behaviour

During preparation of a couple of master slides, I wasn't able to modify text alignment in a text box. More precisely, I could set alignment to center- or right-aligned, but the text would still be displayed left-aligned.

Expected behaviour

"Text" jumps to the center or right side of a text box when setting center- or right-alignment.

Attached a sample document to illustrate the issue: go to View->Master->Slide Master, select the "can't right-align" text box and attempt to modify text alignment.
Comment 1 Buovjaga 2015-10-20 17:56:41 UTC
Confirmed.

Win 7 Pro 64-bit, Version: 5.0.2.2 (x64)
Build ID: 37b43f919e4de5eeaca9b9755ed688758a8251fe
Locale: fi-FI (fi_FI)

Version: 5.1.0.0.alpha1+
Build ID: 186f32f63434e16ff5776251657f902d5808ed3d
TinderBox: Win-x86@39, Branch:master, Time: 2015-10-16_09:42:47
Locale: en-US (fi_FI)

LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
Comment 2 QA Administrators 2016-11-08 11:16:44 UTC Comment hidden (obsolete)
Comment 3 Tomislav Nakic-Alfirevic 2016-11-11 20:28:01 UTC
Checked as instructed, have 4.2.8.2 installed and the bug is still present.
Comment 4 Buovjaga 2016-11-11 20:36:58 UTC
(In reply to Tomislav Nakic-Alfirevic from comment #3)
> Checked as instructed, have 4.2.8.2 installed and the bug is still present.

Checked with a non-ancient version and still confirmed.

Arch Linux 64-bit, KDE Plasma 5
Version: 5.3.0.0.alpha1+
Build ID: 553cfda502a1516673233e409f91372766da6c4d
CPU Threads: 8; OS Version: Linux 4.8; UI Render: default; VCL: kde4; Layout Engine: new; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group
Built on November 11th 2016
Comment 5 QA Administrators 2017-11-12 11:00:58 UTC Comment hidden (obsolete)
Comment 6 Tomislav Nakic-Alfirevic 2017-11-12 12:09:46 UTC
@Buovjaga Could you check with whatever version you have now?

I'm still on the ancient 4.2.8.2, the version shipped with 14.04 LTS, so I wouldn't see the fix if it was applied to a non-ancient version.
Comment 7 Buovjaga 2017-11-12 16:57:01 UTC
I looked inside the styles.xml file after extracting the .odp (as zip). It had this style definition for the problematic text box:

<style:style style:name="Mgr4" style:family="graphic" style:parent-style-name="standard" style:list-style-name="ML3">
      <style:graphic-properties draw:stroke="none" svg:stroke-color="#000000" draw:fill="none" draw:fill-color="#ffffff" draw:textarea-horizontal-align="left" draw:auto-grow-height="true" draw:auto-grow-width="false" fo:min-height="0cm" fo:min-width="0cm" />
</style:style>

When I changed the value of draw:textarea-horizontal-align to "right", the text alignment worked as expected.

So I went about trying to achieve the same in the LibreOffice UI. I succeeded by:
1. Selecting the text box (not entering text edit mode)
2. Right-clicking and selecting Text
3. Changing Text anchor to be in the top right position

After saving the changed file and unzipping again, I could see that draw:textarea-horizontal-align had indeed changed to "right" in the style!

Well, it is still a problem that it does not work with simple paragraph formatting (as it does with new documents), but at least you have a workaround.

Anyway, it is confirmed in the latest master.

If you want a simple way to test newer versions, try the AppImage builds: http://libreoffice.soluzioniopen.com/

Arch Linux 64-bit, KDE Plasma 5
Version: 6.0.0.0.alpha1+
Build ID: d73225119476de1826f648acca9e93bf6797e813
CPU threads: 8; OS: Linux 4.13; UI render: default; VCL: kde4; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group
Built on November 12th 2017
Comment 8 QA Administrators 2018-11-13 03:41:46 UTC Comment hidden (obsolete)
Comment 9 Timur 2019-11-16 11:11:27 UTC
Same with Lo 6.5+ but..
We don't have a cause here nor steps to reproduce and create the problem ODP. Master slide is not relevant, same is if copied to Normal slide. 

We have a workaround in Comment 7 or another: clear direct formatting on that frame. After that, align will work. 
This is Text Frame (as shown in status bar if selected). And I don't know how to add text frame at all in Impress. 

I'm inclined to close this bug. I'd just want to clarify on text frame.
Comment 10 QA Administrators 2021-11-16 04:10:01 UTC Comment hidden (obsolete)
Comment 11 Tomislav Nakic-Alfirevic 2021-11-18 16:39:36 UTC
I'm using 6.0.7.3 ATM and the bug is still present.

I tried creating a new ODP presentation, created a new text field and could not change alignment. Also noticed a mistake in the Format->Align menu which showed two alignments selected at the same time (they should be mutually exclusive, will attach screenshot in a moment).
Comment 12 Tomislav Nakic-Alfirevic 2021-11-18 16:40:13 UTC
Created attachment 176342 [details]
Forat->Align menu bug
Comment 13 BogdanB 2023-05-14 14:58:12 UTC Comment hidden (obsolete)
Comment 14 Buovjaga 2023-05-14 18:10:47 UTC
(In reply to BogdanB from comment #13)
> Can you retest?
> 
> No problem in
> Version: 7.5.3.2 (X86_64) / LibreOffice Community
> Build ID: 9f56dff12ba03b9acd7730a5a481eea045e468f3
> CPU threads: 16; OS: Linux 5.19; UI render: default; VCL: gtk3
> Locale: ro-RO (ro_RO.UTF-8); UI: en-US
> Calc: threaded

How did you test it?

If you open attachment 119743 [details], go to View - Master Slide, focus inside the "can't right-align" text box and go to Format - Align Text, you will see "Right".

That said, the document is somehow a unique problematic example and maybe it is not worth to keep this open (as Timur proposed in 2019).
Comment 15 BogdanB 2023-05-14 18:40:37 UTC
Yes, sorry. Missed some details.
I tried with right click - Paragraph: nothing works. Also with toolbar.

Version: 7.6.0.0.alpha1+ (X86_64) / LibreOffice Community
Build ID: aa0cbe2c82bbc2295b51357378a68da0d64a44a0
CPU threads: 16; OS: Linux 5.19; UI render: default; VCL: gtk3
Locale: ro-RO (ro_RO.UTF-8); UI: en-US
Calc: threaded