Font renders thicker in browsers [closed]
Asked Answered
A

4

18

I am using the Open Sans font on a web site, but it appears much thicker in all browsers than in Adobe Illustrator (see attached images). Why is this and is there any way I can get the font in the browser to display "thinner" please?

Illustrator

Browser

Note Both the browser and Illustrator are rendering the Semibold weight (600)

Angel answered 29/1, 2015 at 14:46 Comment(2)
WRT your edit: Is your question how to make the browser use a thinner font than weight 600?Laurencelaurene
Please post the HTML and CSS code you are using. It is normal to have fonts rendered differently by different programs, but the difference here looks too big to be explainable by that alone.Nicole
A
48

The issue was with aliasing. The following css solution will work for safari, chrome and firefox:

-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
Angel answered 30/1, 2015 at 5:8 Comment(3)
Can anyone explain why this works and what we're losing by setting this?Lagerkvist
@Lagerkvist "Smooth the font on the level of the pixel, as opposed to the subpixel. Switching from subpixel rendering to antialiasing for light text on dark backgrounds makes it look lighter" - developer.mozilla.org/en-US/docs/Web/CSS/font-smoothFootboy
Love this. So much cleaner. Should be the default behaviour in my opinionClamatorial
U
4

Make sure you're including the light (300) and normal (400) weights for Open Sans, then you can simply:

body {
    font-family: 'Open Sans', sans-serif;
    font-weight: 300; /* Or 400, if 300 is too light. */
}
Unoccupied answered 29/1, 2015 at 14:51 Comment(7)
Thanks, please see update to questionAngel
@Angel are you using the same font size? Are you using pt units?Unoccupied
I am using px in both cases.Angel
@Angel can you not simply change the font weight in the browser from Semibold to Normal?Unoccupied
Unfortunately not, the regular and semibold weights appear quite differently.Angel
Don't you mean font-weight instead of font-size?Flotage
@FredericLeitenberger Well spotted.Unoccupied
W
0

The Open Sans Webfont comes in 10 styles. For me it looks like the browser displays the semibold one. It should be regular and you should go fine.

Take a look at fontsquirrel

http://www.fontsquirrel.com/fonts/open-sans

Wart answered 29/1, 2015 at 14:51 Comment(2)
I think you mean "10 weights". There are only 3 different font styles!Laurencelaurene
You're right - I meant styles because all weights have single stylesheets :)Wart
V
-1

The simple answer is that there isn't a fix. If you are properly loading and calling the desired style and weight, then sometimes things just render differently between adobe and web browsers (or browser to browser). Your options are to go to 400 weight or learn to love the boldness.

Vesiculate answered 29/1, 2015 at 18:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.