سؤال

I added <link href='http://fonts.googleapis.com/css?family=Roboto:300,400' rel='stylesheet' type='text/css'> to my HTML page.

I've selected Normal 400 and Light 300 styles, but how do I use them in my CSS.

I've got this in my CSS:

body{
font-family: 'Roboto', sans-serif;
}

In my heading I want to use that Light 300, but how can I?

#heading
{
//what should go here

}
هل كانت مفيدة؟

المحلول

Simply set the font-weight to it's appropriate value:

#heading {
    font-family: 'Roboto', sans-serif;
    font-weight: 300;
}
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top