Unfortunately all impls compute different positions for text-top
, and that the leading-trim: text
value using it doesn't make this property interoperable. I would like the property to provide at least one value that is interoperable across platforms (browsers/OS).
I discussed with @litherum on this before. IIUC we would like to have two text-top/bottom metrics; one which is interoperable, another which is compatible with the current layout engine of the platform.
How about something like:
Value Description platform-text Use the text-top/bottom metric. This value matches to metric used by the layout, but may vary by platform. typo-text Use the text-top/bottom metric usingsTypoAscender
/sTypoDescender
from os/2
table in OpenType fonts, or the tightest metrics on other font systems that can provide multiple text metrics. em-height Use the text-top/bottom metrics using the synthesized em-height metrics. The em-height metrics is computed by normalizing the typo-text
metrics to 1em. For example, the text-top em-height for OpenType is computed by sTypoAscender / (sTypoAscender + sTypoDescender) * font-size
.
The em-height is a metric invented by Gecko, @jfkthame explained here.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.3