• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize


  • Subject: Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize
  • From: Roberto Sobachi <email@hidden>
  • Date: Mon, 16 Feb 2004 15:42:18 +0100

I've got problems assign to NSFont a font and size.

I need to insert into a NSDictionary a NSFont class, but when I start
application it returns that NSFont is nil.

This is my code:

NSFont *fontForString = [NSFont fontWithName:@"Times-Roman" size:9.0];

NSMutableDictionary *myDictionary = [NSMutableDictionary
dictionaryWithObjectsAndKeys: [NSColor whiteColor],
NSForegroundColorAttributeName, fontForString, NSFontAttributeName];






Roberto Sobachi
developer
http://www.xidiar.com
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize
      • From: Aki Inoue <email@hidden>
    • Re: Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize
      • From: Ryan Bates <email@hidden>
  • Prev by Date: how to save styled text
  • Next by Date: Re: Cant't use UTF-8 source files. False string interpretation.
  • Previous by thread: Re: how to save styled text
  • Next by thread: Re: Problems with NSFont and (NSFont *)fontWithName:(NSString *)fontName size:(float)fontSize
  • Index(es):
    • Date
    • Thread