0

Pretty simple question, why does my CSS not render my fonts when I declare it programmatically (in my CSS) vs when I use the @font-your-face UI?

For a number of reasons I'd like to be able to control this from my styles. I'm declaring the CSS font-family declaration correctly and the text is being changed but it's going to some sort of Sans-Serif or Helvetica default.

If it matters I'm using, or trying to use omega 4. thanks in advance.

Here's my css for the relevant selector, I know it's trying to work because the text changes but not to this font.

.l-page{width:960px;
    margin:0 auto;
    border:2px solid black;
    border-radius:15px;
    padding:2px;
    font-family: 'Cassannet - simple';
    font-weight: normal;
    font-style: normal;}
5
  • Just make sure the font is linked into the source, and use font-family as normal. There's nothing else to it, Drupal doesn't (and can't) change how the basic HTML/CSS works
    – Clive
    May 27, 2015 at 8:01
  • Can you clarify what you mean by 'linking the font to it's'source?
    – nizz0k
    May 28, 2015 at 5:07
  • It should be something like the following: @font-face { font-family: 'MyWebFont'; src: url('myfont.woff2') format('woff2'), url('myfont.woff') format('woff'); }. If you are not using anything like this, it doesn't work.
    – apaderno
    May 28, 2015 at 5:38
  • in my css/sass, I assume?
    – nizz0k
    May 28, 2015 at 5:53
  • It seems that the syntax is more complicated than that, any link to a reference?
    – nizz0k
    May 28, 2015 at 6:24

1 Answer 1

1

There is an option to apply the CSS in the theme in the drop down of the @font-your-face UI.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.