Add support for @page margin boxes.
This allows an author to put content (such as custom headers and
footers) in the margin area around the page content area.
https://drafts.csswg.org/css-page-3/#margin-boxes
The spec defines 16 page margin boxes - one for each of the four
corners, and three for each of the four edges. Page margin boxes are
defined via child at-rules inside an @page rule. Such child rules
contain a list of properties. In order to generate a page margin box,
the content property must be set to something. For now, only regular
text content is supported, i.e. no support for counters, images or
quotes yet.
The default content placement defined in
https://drafts.csswg.org/css-page-3/#margin-text-alignment is also not
yet supported.
Vertical-align on page margin boxes behaves as for table cells. See
https://drafts.csswg.org/css-page-3/#page-properties
All writing modes are supported. Had to remove a DCHECK from
MarginPaddingPercentageResolutionSize() in ConstraintSpace. If a page
margin box establishes an orthogonal writing mode root, the percentage
resolution size is already set correctly.
Bug: 40341678
Change-Id: I469e1f375135dd530e9aa6fb1550324754d8eba6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5625632
Reviewed-by: Rune Lillesveen futhark@chromium.org
Commit-Queue: Morten Stenshorne mstensho@chromium.org
Reviewed-by: Ian Kilpatrick ikilpatrick@chromium.org
Cr-Commit-Position: refs/heads/main@{#1316486}