Bug 162618 (layoutInCell) - [META] MSO layoutInCell / LO IsFollowingTextFlow
Summary: [META] MSO layoutInCell / LO IsFollowingTextFlow
Status: NEW
Alias: layoutInCell
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:doc, filter:docx, filter:odf
Depends on: 60205 113373 133522 135943 148550 162612 51131 77794 79186 87569 91632 104596 109411 115094 115896 116256 119038 124601 129888 130120 136613 137590 153045 153909 154855 156318 157637 157707 159453 160077 162211 162304 162539 162541 162542 162551
Blocks:
  Show dependency treegraph
 
Reported: 2024-08-24 19:40 UTC by Justin L
Modified: 2024-09-07 17:11 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Justin L 2024-08-24 19:40:31 UTC
layoutInCell (Microsoft formats)  (allowincell in VML)
 * only has effect in tables AFAIK
 *forces the shape to be contained inside the cell (the cell expands to encompass a large shape)
 ** exception: for vertical, it forces containment within the cell margins
 ** exception: if wrap-through, then fromTop or fromLeft can escape from the cell
 * margin orientation now refers to cell margin (the area the text can fit in - after the border spacing)
 * “page” orientation now refers to cell frame
 ** exception: for vertical, it refers to the cell margin
 * the default value (if not specified) is true
 ** exception: apparently layoutInCell is always considered true if vertical orientation is “line” or horizontal orientation is “character”
 ** exception: since Word 2013 (compatibilityMode 15), layoutInCell is always considered true
 * if NOT layoutInCell, “paragraph” orientation does not refer to the anchor paragraph, but to the line on which the table appears. (i.e. the shape is to be placed outside of the table)
 ** exception: all shapes are treated as “wrap-through”

Documentation quote: “Specifies how this DrawingML object behaves when its anchor is located in a table cell; and its specified position would cause it to intersect with a table cell displayed in the document. That behavior shall be as follows:
 * When this attribute has a value of true , then the object shall be positioned within the existing table cell, causing the cell to be resized as needed. This means that all positioning shall be relative to the cell and not the line on which the table appears.
 * When this attribute has a value of false, then the object shall be positioned as specified, but the table shall be resized and/or relocated within the document as needed to accommodate the object. This means that all positioning shall be relative to the line on which the table appears and not the cell in which the anchor is present.”


FollowTextFlow (LibreOffice formats) style:flow-with-text
 * created in OOo to implement layoutInCell
 * applies to tables, pages, header/footer, footnote/endnote, floating frames
 * “page text area” refers to the container’s text area
 * “entire page” orientation now refers to the container frame
 * the default value (if not specified) is false
 * if NOT following text flow, “paragraph” orientation still naturally refers to the anchor paragraph.

Docuemntation quote: “The style:flow-with-text attribute specifies whether a drawing shape flows with the text of its layout environment or not. The layout environment of a drawing shape is determined by the location of its anchor.”
Comment 1 Justin L 2024-09-07 17:08:01 UTC
The RTF format does not natively support layoutInCell.
In MS Word - it is implemented as a name/value pair extension.

{\sp{\sn fLayoutInCell}{\sv 1}}
Comment 2 Justin L 2024-09-07 17:11:54 UTC
(In reply to Justin L from comment #0)
>  * if NOT layoutInCell
>  ** exception: all shapes are treated as “wrap-through”
Not true. This might be caused by Word's UI, but not by the layout engine.