Bug 161647 - Allow headers to be aligned vertically to bottom
Summary: Allow headers to be aligned vertically to bottom
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-19 07:27 UTC by Mike Kaganski
Modified: 2024-06-28 05:43 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
A possibly-multiline fixed-height header (54.06 KB, application/vnd.oasis.opendocument.text)
2024-06-19 07:47 UTC, Mike Kaganski
Details
The same using a table in header (54.32 KB, application/vnd.oasis.opendocument.text)
2024-06-19 07:52 UTC, Mike Kaganski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Kaganski 2024-06-19 07:27:12 UTC
In bug 33304 comment 54, I mention, that there is an existing problem that does not allow creation of headers that dynamically change their layout *from bottom to top*, taking space above, not below.

The use case:
Imagine that you are creating a book, with the current chapter heading repeated in the page headers. You want the page layout be like this (from top): 0.5 cm margin; then 1.5 cm header (the space enough to pot up to two lines of header text); then text body. The text body must start 2 cm below the page edge, and never move because of headers content. You need the header content be aligned to the bottom - so that no matter if the header is 1-line, or 2-line, its bottom is immediately above the text body.

Currently, this is impossible directly. Putting the header text to a fixed 1.5-cm header will make it aligned to the top of that 1.5 cm space. Making the header smaller height and dynamically expanding would not make it take the space above, but the space below, which would move the text body.

A workaround is to put a table into the header, which will allow to use the vertical alignment in the cells.

This enhancement request is to add a vertical alignment to headers, to allow the wanted behavior without workarounds. In addition, this would enhance interoperability with other office suites, because this would allow easier re-creation of their layout, by maximizing the header height into the margin area, and making the headers bottom-aligned, which would create the same placement of the header content.
Comment 1 Mike Kaganski 2024-06-19 07:47:37 UTC
Created attachment 194814 [details]
A possibly-multiline fixed-height header

This sample shows what can be done now: the header is top-aligned,so its content is separated from body text by a variable spacing: on the first page, the spacing of the single-line header is very big; on the second page, the two-line header ends closer to the page body - but still not immediately "attached" to the body, as the author intended
Comment 2 Mike Kaganski 2024-06-19 07:52:44 UTC
Created attachment 194815 [details]
The same using a table in header

This sample has a table in the header, which is set to 15 mm high, and its cell has to-bottom text alignment. This is the *wanted* layout - see how the header text is aligned to the bottom of the header area on both pages, no matter if the content is 1-line or 2-line
Comment 3 Justin L 2024-06-27 19:02:55 UTC
AFAICS, doing this would be a problem when exporting to MS formats. At least in Word's UI I don't see a similar capability.

Well, at least for the MS header. The header is always top aligned - as defined by "Header from top" which defaults to 1/2 inch. A second line in the header moves closer to the body text - the same as LO now does it. So MSO "Header from top" == LO "page top margin", and MSO "page top margin" == LO "margin + header height + spacing".

The MS footer is basically the reverse of the header. So the footer is always bottom aligned (which LO can mimic nicely with its dynamic spacing feature).

So from what I can see, this requested feature could not be exported to DOCX format. (In other words, it might be best to force the table workaround for those who really want this kind of layout.)
Comment 4 Mike Kaganski 2024-06-28 05:43:33 UTC
(In reply to Justin L from comment #3)

Indeed, you are right. I must say, that I didn't imply that other office suites have this feature; I only meant that having this feature, we can re-create the layout that they have, more easily. I know that I had a clear idea how would it be possible - but when I try to re-create my idea now, I can't remember what I meant ... shame on me: it was only a bit more than a week ago :-(

While this would be a nice feature, with the opposite interoperability concern that you raised, it is very valid to WONTFIX.