Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

font-weight for custom fonts

Tags:

css

fonts

I'm using my custom fonts defined like this:

@font-face {
  font-family    : 'LatoWeb';
  src            : url('../resources/fonts/Lato-Regular.woff') format('woff');
  font-style     : normal;
  font-weight    : normal;
  text-rendering : optimizeLegibility;
}

What's interesting is that I don't have font-weight variations for this font. However, starting from font-weight: 600 the font gets bolder, how's that possible? Where does it take the font if it's not loaded?

like image 556
Max Koretskyi Avatar asked Jan 20 '26 02:01

Max Koretskyi


1 Answers

@font-face {
  font-family    : 'LatoWeb';
  src            : url('../resources/fonts/Lato-Regular.woff') format('woff');
  font-weight    : normal;
  font-style     : normal;
  text-rendering : optimizeLegibility;
}

also you can use:

for example :
font-weight:normal
font-weight:bold

100    Extra Light or Ultra Light
200    Light or Thin
300    Book or Demi
400    Normal or Regular
500    Medium
600    Semibold, Demibold
700    Bold
800    Black, Extra Bold or Heavy
900    Extra Black, Fat, Poster or Ultra Black
like image 184
Dhaval Gadher Avatar answered Jan 21 '26 23:01

Dhaval Gadher



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!