• 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: text to bezier path
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: text to bezier path


  • Subject: Re: text to bezier path
  • From: Douglas Davidson <email@hidden>
  • Date: Mon, 4 Jun 2007 13:08:41 -0700


On Jun 4, 2007, at 12:45 PM, Chase wrote:

I'm trying to draw text with outline of a user-specified thickness (in pixels). I had to do something similar in a REALbasic app once, and the effect was achieved by drawing once with a stroke thickness twice that of the user-specified "text outline thickness" and then drawing the original text again, directly over the top (with no outline this time).

It's not clear to me exactly what kind of effect you want, but with simple attributes you can specify independent stroke and fill colors as well as the stroke width. Use NSForegroundColorAttributeName, NSStrokeColorAttributeName, and NSStrokeWidthAttributeName. The stroke width is not in pixels, but is relative to the font size, so you would need to set it in your text on a per-font-size basis. See the comments in AppKit/NSAttributedString.h for the exact interpretation of the values.


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


  • Follow-Ups:
    • Re: text to bezier path
      • From: Paul Bruneau <email@hidden>
References: 
 >text to bezier path (From: "Chase" <email@hidden>)

  • Prev by Date: Re: text to bezier path
  • Next by Date: Re: Question about NSArrayController
  • Previous by thread: text to bezier path
  • Next by thread: Re: text to bezier path
  • Index(es):
    • Date
    • Thread