On Thu, May 3, 2012 at 11:58 AM, Markus Ernst <derer...@gmx.ch> wrote: > Am 03.05.2012 17:45 schrieb Tom Livingston: > >> On Thu, May 3, 2012 at 11:41 AM, Markus Ernst<derer...@gmx.ch> wrote: >>> >>> Am 03.05.2012 17:24 schrieb Tom Livingston: >>> >>>> On Thu, May 3, 2012 at 10:54 AM, Philippe Wittenbergh<e...@l-c-n.com> >>>> wrote: >>>>> >>>>> >>>>> >>>>> On May 3, 2012, at 10:56 PM, Tom Livingston wrote: >>>>> >>>>>> If I'm using "RobotoBold" - custom font - in my stack on an<h2> for >>>>>> example, I have to spec font-weight: normal; as well because otherwise >>>>>> it "double-bolds" the font. But if the user sees a fallback font of >>>>>> Helvetica or Arial, they won't get it in a bold weight. Is there >>>>>> anything that can be done about this that I'm not seeing? Can only the >>>>>> fall backs be bold? >>>>> >>>>> >>>>> >>>>> I'm not sure I understand. Care to put an example ? >>>>> >>>>> @fontface { >>>>> font-family: RobotoBold; >>>>> src: url(RobotoBold.woff); >>>>> font-weight: bold; >>>>> } >>>>> >>>>> h2 { font-family: RobotoBold, Helvetica, Comic Sans; font-weight: bold; >>>>> } >>>>> >>>>> with that there should not be any artificial bolding. Browser will >>>>> (should) treat that font as being a bold face. >>>>> >>>>> Philippe >>>>> -- >>>>> Philippe Wittenbergh >>>>> http://l-c-n.com/ >>>>> >>>>> >>>>> >>>> >>>> One other thing. After thinking about this, WHY doesnt this still >>>> double-bold the custom font? Just a function of @font-face? >>> >>> >>> >>> It should not double-bold if your code is ok... can you provide a link to >>> your page? >> >> >> I was able to solve my problem with Philippe's help. >> >> But I am curious why specing font-weight: bold; in the @font-face >> declaration doesn't double-bold a bold face custom font, when specing >> font-weight: normal; in the @font-face declaration and font-weight: >> bold; on an element DOES double-bold a bold face custom font. > > > Ah, sorry for mis-reading your question. The font-weight property in > @font-face does tell the browser to use this font whenever a bold weight is > required. Thus, it _prevents_ the browser from boldening it. This is > necessary to make web fonts useable just as other fonts - you can combine > them into families: > > @fontface { > font-family: MyFont; > src: url(MyFontNormal.woff); > font-weight: normal; > font-style: normal; > } > @fontface { > font-family: MyFont; > src: url(MyFontBold.woff); > font-weight: bold; > font-style: normal; > } > @fontface { > font-family: MyFont; > src: url(MyFontItalic.woff); > font-weight: normal; > font-style: italic; > } > @fontface { > font-family: MyFont; > src: url(MyFontBoldItalic.woff); > font-weight: bold; > font-style: italic; > } > > Then you can use font-family:MyFont in your CSS, and apply bold and italic > styles as you would apply them to Arial or Georgia.
Super! Thanks for clearing that one up. So simple... can't see the forrest for the trees and all that... -- Tom Livingston | Senior Interactive Developer | Media Logic | ph: 518.456.3015x231 | fx: 518.456.4279 | mlinc.com ______________________________________________________________________ css-discuss [css-d@lists.css-discuss.org] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/