• 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: glyphWithName: broken on Tiger ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: glyphWithName: broken on Tiger ?


  • Subject: Re: glyphWithName: broken on Tiger ?
  • From: glenn andreas <email@hidden>
  • Date: Wed, 1 Jun 2005 15:07:42 -0500


On Jun 1, 2005, at 2:43 PM, Robert Clair wrote:

The line of code

NSGlyph glyph = [font glyphWithName: @"T"];

 now returns 0 (null glyph) for any font I've tried it with.


Considering that glyph names are font specific to start with (and there is no universal standard), this may not have ever worked on some fonts. Blame the font designers for this one...


I know all about the lack of correspondence between characters and glyphs but all I want is the glyph for a stand-alone "T" so I can get the Bezier paths. An NSLayoutManger would be major overkill here. This works on Panther.


An NSLayoutManager isn't all that bad (you could even wrap it all up into a utility routine that resuses the layout manager between calls), and, more to the point, the "correctest" way to handle this (and far easier than trying to manually parse the font file to get the character->glyph mapping).




Glenn Andreas                      email@hidden
 <http://www.gandreas.com/> wicked fun!
Widgetarium | the quickest path to widgets

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: glyphWithName: broken on Tiger ?
      • From: Robert Clair <email@hidden>
References: 
 >glyphWithName: broken on Tiger ? (From: Robert Clair <email@hidden>)

  • Prev by Date: Re: Bindings Basics: selections
  • Next by Date: Re: glyphWithName: broken on Tiger ?
  • Previous by thread: glyphWithName: broken on Tiger ?
  • Next by thread: Re: glyphWithName: broken on Tiger ?
  • Index(es):
    • Date
    • Thread