Reputation: 1851
the following font style code does not work in firefox, I tested it in chrome and iexplorer and it works, so must be a compatibility problem.
font: italic normal normal normal 12px/15.3599996566772px Helvetica, Arial, 'lucida grande', tahoma, verdana, arial, sans-serif;
Can someone confirm it, or maybe there's an alternative for firefox.
FIX:
font: italic normal normal 12px/15.3599996566772px Helvetica, Arial, 'lucida grande', tahoma, verdana, arial, sans-serif;
Upvotes: 1
Views: 324
Reputation: 201558
This appears to be a bug in Firefox. In the Developer Tools, no errors are shown, but when inspecting style sheets, the styles for the element are empty.
A quick workaround is to remove of the normal
keywords (or all of them, since they are redundant: all sub-properties not set explicitly in a font
shorthand are set to their initial values).
P.S. Your code is correct, Firefox just does not handle it well. As a reference to font
shorthand syntax (if you use it), use the W3C CSS 2.1 specification.
Upvotes: 1
Reputation: 7771
For FireFox, you should set all the properties without using the shorthand property. font:
is the shorthand property for many other font properties:
Instead it should look like this:
font-family: monospace;
font-size: 20px;
font-weight: bold;
color: blue;
Upvotes: 1