• 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
Re: Font-related crash in drawing method on PowerPC machines
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Font-related crash in drawing method on PowerPC machines


  • Subject: Re: Font-related crash in drawing method on PowerPC machines
  • From: Rob Keniger <email@hidden>
  • Date: Wed, 23 Apr 2008 15:33:25 +1000


On 23/04/2008, at 1:16 AM, I. Savant wrote:

 I haven't looked at this in detail and don't know if this has
anything to do with your problem, but how are you handling the case
where the user has disabled or otherwise modified their fonts? Even
system fonts can be screwed with and if the font is not available,
assuming it always will be is probably "Not a Good Idea™".


To be more specific, in this case you are asking for these fonts:

[NSFont fontWithName:@"Lucida Grande" size:16.0]
[NSFont fontWithName:@"Lucida Grande Bold" size:16.0]

When you should probably be using:

[NSFont systemFontOfSize:16.0];
[NSFont boldSystemFontOfSize:16.0];

I also don't think you need to call -beginEditing and -endEditing on a normal NSMutableAttributedString, this only makes sense if the string is an NSTextStorage or similar.

That said, I can't see anything obvious that would cause a crash.

--
Rob Keniger



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Font-related crash in drawing method on PowerPC machines (From: "Justin Williams" <email@hidden>)
 >Re: Font-related crash in drawing method on PowerPC machines (From: "I. Savant" <email@hidden>)

  • Prev by Date: Re: How to create shortcuts after installing the my package
  • Next by Date: Re: Resource Fork - is this a good use/the right thing to do?
  • Previous by thread: Re: Font-related crash in drawing method on PowerPC machines
  • Next by thread: Calling NSNumber class methods on NSDecimalNumber
  • Index(es):
    • Date
    • Thread