Skip to content
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

Coverage html report lineno font-size too small #748

Closed
whusnoopy opened this issue Jan 4, 2019 · 2 comments
Closed

Coverage html report lineno font-size too small #748

whusnoopy opened this issue Jan 4, 2019 · 2 comments

Comments

@whusnoopy
Copy link

The CSS defined in html report styles.css set line number font-size to 10px, but Chrome have a minimal font-size setting which with 12px as default, so the font-size for lineno will render as 12px, and the line-height will show as 1.6x12 = 19.2, it cause the lineno tall than code, code part is still with font-size 12px (0.75em) and line-height 16px (1.333333em)

font-size: .625em; /* 10/16 */


We can suggest users to change their Chrome minimal font-size to 10px or smaller to ignore this problem, but for others doesn't know the reason, maybe we can change the font-size of lineno to 12px for a better way?

@nedbat
Copy link
Owner

nedbat commented Jan 4, 2019

Thanks, I had never seen the minimum font size setting before. The default for me (and a number of people I asked) is 6 point, do you know why it was 12 for you?

I've fixed this a slightly different way than your pull request. Your way gave everyone 12-point line numbers. My way leaves the default as 10, but keeps the alignment correct if the size is actually 12 due to the minimum font setting.

@nedbat nedbat closed this as completed Jan 4, 2019
@whusnoopy
Copy link
Author

Thanks for the better way!

As https://bugs.chromium.org/p/chromium/issues/detail?id=36429 said, Chrome set minimal font-size to 10/12px for Simp/Trad Chinese, Japanese, Korean and Thai, and my locate is ZH-cn (Simp Chinese), that's why I got the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants