-
Notifications
You must be signed in to change notification settings - Fork 642
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-inline-3][css-writing-modes] Baseline Alignment of Mixed Vertical Orientations #5424
Comments
Proposal:
|
To make a concrete example, let's say the vertical baseline table of the font places alphabetic and central baselines at 50/100, and the horizontal baseline table places alphabetic at 10/100 and central at 40/100. It's clear, I think, that in typical vertical typesetting, the upright runs and the sideways runs should be aligned to each other by the central baseline. But it's less clear what should happen if alignment by alphabetic baseline is requested. If we follow the proposal above:
I think this will work reasonably when aligning child text with an orientation mismatched to its parent. However, it is not a symmetrical operation: the result of aligning two runs depends on which orientation is considered the context and which is considered the intruder, because that determines whether we use the horizontal or vertical baseline table. For aligning a box within another box, there is a natural answer to this question. But for mixed orientation boxes: is the context sideways or upright? |
In CSS Writing Modes, text and inline boxes are aligned using the central baseline. This gives the correct behavior across font changes and also across orientation changes.
However,
dominant-baseline
andalignment-baseline
properties introduced by SVG / CSS Inline Layout Level 3 allow changing the baseline away fromcentral
. When orientations are mixed, this can result in some nonsensical things. For example, vertical baseline tables often set their alphabetic baseline to coincide with the central baseline. If you try to align an upright run (where the alphabetic baseline is central) with a sideways run (where the alphabetic baseline is to one side of the run) the result will not make any sense. They are trying to align using two different, incompatible baseline tables, essentially.I think we need to make some special rules for when sideways and upright text are aligned to each other.
Note: This issue is derived from @kojiishi’s #5381, but it's about baseline metrics instead of ascent/descent.
The text was updated successfully, but these errors were encountered: