Skip to content

[css2][css-align] vertical-align: baseline's specced behavior when the box doesn't have a baseline isn't great for CJK #9931

Open
@hober

Description

@hober

CSS2 defines vertical-align: baseline like so (emphasis mine): Align the baseline of the box with the baseline of the parent box. If the box does not have a baseline, align the bottom margin edge with the parent’s baseline.

This is great if the parent's baseline is the alphabetic baseline. But if we're using a central baseline because the parent's text is CJK, what you really want is to align the box's midline (halfway between the top and bottom margin edges?) with the parent's central baseline.

The workaround is to use vertical-align: middle, but that doesn't actually do what you want and you have to tweak by hand with margin and padding to get it right, which is very brittle.

See also #7578 and #9520.

Metadata

Metadata

Assignees

Labels

CSS2Commenter Response Pendingcss-align-3Current Worki18n-trackerGroup bringing to attention of Internationalization, or tracked by i18n but not needing response.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions