Bug 65412 - Framestyle setting "mirror on even pages" lost if horizontal position is "center"
Summary: Framestyle setting "mirror on even pages" lost if horizontal position is "cen...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: x86 (IA32) All
: medium minor
Assignee: Not Assigned
Whiteboard: BSA
: 159870 (view as bug list)
Depends on:
Blocks: Frame
  Show dependency treegraph
Reported: 2013-06-05 11:40 UTC by Fabio Bugnon
Modified: 2024-03-10 18:07 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:

Frame's option used to reproduce the bug (61.04 KB, image/png)
2013-06-05 11:40 UTC, Fabio Bugnon
Test file created according to the "Steps to reproduce the bug" (8.62 KB, application/vnd.oasis.opendocument.text)
2013-06-05 11:47 UTC, Fabio Bugnon
Picture in page margin (29.04 KB, application/vnd.oasis.opendocument.text)
2015-10-30 09:58 UTC, Regina Henschel

Note You need to log in before you can comment on or make changes to this bug.
Description Fabio Bugnon 2013-06-05 11:40:37 UTC
Created attachment 80338 [details]
Frame's option used to reproduce the bug

Problem description (short): 
When creating a FRAME anchor to page, using "mirror on even pages" option will not be saved when setting horizontal POSITION to center.

Problem description (long): 
I use mirrored page style in order to print on two sides keeping a larger inside margin.
So I use a frame, placed on the outside border of pages, to number the document pages (I know I can use the footer, I just like better this way).  And I use the option "mirror on even pages" in order to keep it on the outside border.
But if I select horizontal position to center, when I close the document, next time I open it the option "mirror on even pages" is no longer marked and the frame is always on the right side.
The problem does not occur when setting horizontal position to anything different than "center" (inside, outside, from inside).

Steps to reproduce:
1. Open a .odt document
2. Go to Insert > Frame and on the window that appears:
3. change "Anchor" to page; check the box "Mirror on even pages"; and change "Position" "Horizontal" (Center) to "Outer page border".  Press OK.
4. Go to Insert > Manual Break > Page Break > OK (in order for the documento to have 2 pages) or press enough times "Enter".
5. Select the Frame created on step 2-3 and copy (Ctrl + C)
6. Click anywhere on to the second page of the document and paste it (Ctrl + V).
(You should see, on the first page a Frame on the right side and, on the second page a frame on the left side)
7. Save the document and close it.
8. Reopen the document
(Now you should see Frames on the right side on both pages)
9. If you enter into the Frame's proprieties, will see the option "Mirror on even pages" is no longer marked.

Current behavior:
"Mirror on even pages" option is not saved.
(when the Frame's configuration is set to (i) Anchor to Page; and (ii) Horizontal Position to Center)

Expected behavior:
Option "Mirror on even pages" should be saved no matter what Frame's configurations I choose.           
Operating System: Ubuntu
Version: release
Comment 1 Fabio Bugnon 2013-06-05 11:47:52 UTC
Created attachment 80339 [details]
Test file created according to the "Steps to reproduce the bug"
Comment 2 Dominique Boutry 2013-10-15 14:59:59 UTC
The option "mirror on even pages" automatically changes the horizontal position depending of the parity of page number ; if it is "centered", no effect; on even page, an "inside" is drawn outside ans and "outside" is drawn inside.

This doesn't allow LibO to uncheck the option by itself when the position is "centered". For instance, if you write some text with blank color on blank background, does that allow LibO to scratch yout text characteristics (size, bold, etc) ? Of course not : it is the same here. At best LibO can grey the checkbox with its current content, when the horizontal position is set at "center".

Reproduced on LibO Simplified steps :
1. in a New empty .odt document, Insert > Frame
2. change "Anchor" to "to page" ; check the box "Mirror on even pages"
3. verify that "Position" "Horizontal" is "Center" ; Press OK
4. Save the document, close it (important) and reopen it
5. double clic on the frame border : in the dialog box, you see that the box "Mirror on even pages" is now unchecked.

So BUG. Reproduced on LibO Win7.
Comment 3 Julien Nabet 2014-02-22 11:35:18 UTC
On pc Debian x86-64 with master sources updated yesterday, I can still reproduce this.
Comment 4 Joel Madero 2015-05-02 15:42:26 UTC Comment hidden (obsolete)
Comment 5 Buovjaga 2015-06-20 16:06:18 UTC

Win 7 Pro 64-bit Version:
Build ID: 3ecef8cedb215e49237a11607197edc91639bfcd
TinderBox: Win-x86@62-merge-TDF, Branch:MASTER, Time: 2015-06-19_23:16:58
Locale: fi-FI (fi_FI)
Comment 6 Regina Henschel 2015-10-30 09:58:20 UTC
Created attachment 120097 [details]
Picture in page margin

The page style is set to "mirrored" and the frame styles "Marginalia" and "MarginaliaCenter" have both set "mirror on even pages" and horizontal "Outer page border". The only difference is, that "Marginalia" has horizontal "Inside" and "MarginaliaCenter" has horizontal "Center". Unpack the document and look into the styles.xml to verify the settings.

There are two images, one has assigned style "Marginalia" and the other "MarginaliaCenter".

Open the document. Notice, that the image, which has got style "MarginliaCenter" is in the wrong margin. This happens because the style "MarginaliaCenter" looses the setting "mirror on even pages" on opening.

This is a FILE OPEN error inherited from OpenOffice.
Comment 7 Regina Henschel 2015-10-30 12:04:11 UTC
It seems, that it is currently not possible to reflect the setting "mirror on even pages" in ODF. ODF knows only the setting page|frame|paragraph-start-margin and "start-margin" is mirrored only in case of "from-inside", "inside" and "outside", read section 20.291 style:horizontal-rel. I remove FILEOPEN therefore.

It is not possible to describe, that a frame should be centered to the outer page margin, because the distinction between even and odd is not made directly in the attribute but indirectly via the style:horizontal-pos attribute (section 20.290)

I think, it is "broken by design".

Immediately: Uncheck and disable the check box "mirror on even pages" in case the horizontal position "center" is chosen. That way the user is warned, that such setting is not possible.

Long term: ?? A new value "center-even-odd" for attribute "horizontal-pos" which triggers even-odd toggle? Or remove the even-odd toggle feature from the horizontal-pos attribute and make an independent attribute "start-end-toggled-on-even-pages"?

Unfortunately it is not possible to define a new attribute _value_ in an own namespace; that is only possible for whole attributes.
Comment 8 QA Administrators 2016-11-08 12:01:34 UTC Comment hidden (obsolete)
Comment 9 QA Administrators 2019-12-03 14:10:20 UTC Comment hidden (obsolete)
Comment 10 Regina Henschel 2021-03-03 14:36:50 UTC
The error still exists in Version: (x64) / LibreOffice Community
Build ID: e60bebd4c5257b0f592d27c74399de1498ac725b
CPU threads: 8; OS: Windows 10.0 Build 19041; UI render: Skia/Raster; VCL: win
Locale: de-DE (en_US); UI: en-US
Calc: CL
Comment 11 QA Administrators 2023-03-04 03:32:58 UTC Comment hidden (obsolete)
Comment 12 Klim 2023-03-10 12:25:35 UTC
The error still exists in Version: (X86_64) / LibreOffice Community
Build ID: 5a235634ca5761aa4b330ebf7e3a2083b7db1606
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Vulkan; VCL: win
Locale: ru-RU (ru_RU); UI: en-US
Calc: CL threaded

The error still exists in Version: (x64) / LibreOffice Community
Build ID: 5b1f5509c2decdade7fda905e3e1429a67acd63d
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: ru-RU (ru_RU); UI: ru-RU
Calc: CL
Comment 13 Dieter 2024-03-10 17:59:48 UTC
*** Bug 159870 has been marked as a duplicate of this bug. ***
Comment 14 ajlittoz 2024-03-10 18:07:47 UTC
Error still present in
Version: (X86_64)
Build ID: 60(Build:2)
CPU threads: 4; OS: Linux 6.7; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fr-FR (fr_FR.UTF-8); UI: en-US
Calc: threaded