Description
https://drafts.csswg.org/css-inline/#initial-letter-wrapping says:
The rule for matching the character grid is 1ch × n + letter-spacing × (n - 1), where n is the size of the initial letter as specified by the initial-letter property.
This seems wrong on two accounts:
-
This value is meant for CJK uses. The
ic
unit is the relevant one, not thech
unit. If we want to support aligning to a grid for latin monospaced fonts, we could make this depend oninitial-letter-align
, and useic
when it is set toideographic
andch
when it is set toalphabetic
, but I am not sure it is worth doing, as Initial letters on monospaced latin text seems unusual. -
n
shouldn't be the size of the initial letter as specified by the initial-letter property. That would result in a too small exclusion area when the line gap is large (or when the initial-letter text is long).
Here's an example of initial-letter: 2
with a large line gap in vertical text. Each [ ]
represents a 1ic
square.
[ ] ____|____
[ ] ' _____ '
[ ] /
[ ] /
[ ] ---+---
[ ] |
[ ] |
[ ] ’
[ ] [ ] [ ]
[ ] [ ] [ ]
[ ] [ ] [ ]
[ ] [ ] [ ]
Here, the exclusion area needs to be 8ic + 7 × letter-spacing
, not 2ic + 1 × letter-spacing
.
I suggest replacing that sentence with something like this:
The size of the exclusion area in the inline direction must be
1ic × n + letter-spacing × (n - 1)
where n is the smallest integer for which the exclusion area is equal or larger than the advance measure of the initial letter.