Normalize.css: Slight clipping of input text in Chrome 73

Created on 1 Apr 2019  路  1Comment  路  Source: necolas/normalize.css

image

The corresponding CSS is:

https://github.com/necolas/normalize.css/blob/fc091cce1534909334c1911709a39c22d406977b/normalize.css#L160-L169

Changing line-height to 1.2 or greater fixes the clip.

I'm not experiencing this issue in Firefox 65 though.

Related #769

Most helpful comment

The descenders (the "g" characters) are clipping because the particular font-family in use here has a computed content-area height that is significantly more than the computed virtual-area height (that is, the line-height). This might help illuminate the issue: https://iamvdo.me/en/blog/css-font-metrics-line-height-and-vertical-align

The corresponding CSS rules you cited presuppose that the font-family that's getting inherited has a computed content-area that's within a typical (normal) range.

line-height: normal is based on font metrics. Using it in this situation will likely prevent clipping,

It would be good to have a reduced test case that loads the font-family depicted in your screenshot

>All comments

The descenders (the "g" characters) are clipping because the particular font-family in use here has a computed content-area height that is significantly more than the computed virtual-area height (that is, the line-height). This might help illuminate the issue: https://iamvdo.me/en/blog/css-font-metrics-line-height-and-vertical-align

The corresponding CSS rules you cited presuppose that the font-family that's getting inherited has a computed content-area that's within a typical (normal) range.

line-height: normal is based on font metrics. Using it in this situation will likely prevent clipping,

It would be good to have a reduced test case that loads the font-family depicted in your screenshot

Was this page helpful?
0 / 5 - 0 ratings

Related issues

visicode picture visicode  路  5Comments

ibrahemMR picture ibrahemMR  路  3Comments

gitowiec picture gitowiec  路  6Comments

slim-hmidi picture slim-hmidi  路  3Comments

FDiskas picture FDiskas  路  3Comments