Re: How to get an italic font

2009-12-04 Thread Gerriet M. Denkmann
On 4 Dec 2009, at 14:44, mlist0...@gmail.com wrote: > Is there some reason you can't use -[NSFontManager convertFont:toHaveTrait:] ? No reason at all, except my ignorance of this method. > It "returns a font whose traits are the same as those of the given font, > except that the traits are cha

Re: How to get an italic font

2009-12-03 Thread mlist0...@gmail.com
Is there some reason you can't use -[NSFontManager convertFont:toHaveTrait:] ? It "returns a font whose traits are the same as those of the given font, except that the traits are changed to include the single specified trait." So something like: NSFont* myFont = [your code here]; NSFont* myIta

How to get an italic font

2009-12-03 Thread Gerriet M. Denkmann
I want an italic font corresponding to an existing font. I tried: NSFontDescriptor *fd1 = [ NSFontDescriptor fontDescriptorWithName: @"Times" size: textFontSize ]; NSLog(@"%s text NSFontDescriptor %@",__FUNCTION__, fd1); // NSFontNameAttribute = Times; NSFontSize