Re: Glyph from Character
Re: Glyph from Character
- Subject: Re: Glyph from Character
- From: Gordon Apple <email@hidden>
- Date: Wed, 21 Mar 2007 18:40:12 -0500
Thanks. I'll do that, or whatever it takes to get it done. The point was
that this was originally going to be a 5 minute task to create a couple of
more test cases/examples for my generic text container. I saw
"appendBezierPathWithGlyph" and said "oh boy, all I need is a glyph index
for the "?" and "&" that I wanted to use". Then I descended into the morass
of obtaining the glyph index and got more and more frustrated with it.
I show a couple of examples near the end of <www.ed4u.com/textflow> should
give you an idea of what I was really trying to do and why I wanted the
Bezier path outlines of individual large glyphs. It would be a good feature
to let the user pick a character and font to use.
> If you want ease of use, here is what you do: create a text view, call
> setString: and setFont: on it, then ask its layout manager for the glyph at
> index 0. When you use the glyph with NSBezierPath, I suggest obtaining the
> font from the text view's text storage rather than using the font you
> originally set, because it is always possible that the font you supplied might
> not have been able to render the character in question, in which case another
> font will have been substituted for it.
>
> Douglas Davidson
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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