https://bugs.documentfoundation.org/show_bug.cgi?id=135464

            Bug ID: 135464
           Summary: ODF export: text:anchor-type="page" +
                    style:horizontal-rel="paragraph" etc. invalid
                    combinations
           Product: LibreOffice
           Version: Inherited From OOo
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Writer
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected]

Writer can produce documents with combinations of anchor-type and
horizontal-rel that are invalid according to ODF 1.3, 20.298
style:horizontal-pos.

for "page" anchor, "paragraph", "paragraph-content", "paragraph-end-margin",
"paragraph-start-margin", "char" are invalid.

to create such a document:
1. insert a shape (or image/frame/ole, 2 different implementations of it)
2. use context menu "Anchor->To Page"

now the Properties dialog will show Page (because the actual value "Paragraph
area" isn't valid) but when you save the file it actually writes "paragraph".

it looks like if the anchor is FLY_AT_PAGE, the anchor frame is always going to
be SwPageFrame, and there is only one difference in the layout code that i can
find where things are different between the horizontal-rel values:

flylay.cxx: CalcClipRect() has this:

            if( rH.GetHoriOrient() != text::HoriOrientation::NONE &&
                rH.GetRelationOrient() == text::RelOrientation::PRINT_AREA )
            {
                aRectFnSet.SetLeft( rRect, aRectFnSet.GetPrtLeft(*pClip) );
                aRectFnSet.SetRight(rRect, aRectFnSet.GetPrtRight(*pClip));
            }

but no corresponding case for PAGE_PRINT_AREA.

so i hope we might be able to easily fix this on ODF import for 3 of the 4
invalid cases.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to