• 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
NSAttributedString drawing and NSText drawing
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSAttributedString drawing and NSText drawing


  • Subject: NSAttributedString drawing and NSText drawing
  • From: email@hidden
  • Date: Mon, 29 May 2006 19:01:38 +0200

Dear List,

I have an application where I need to do in place editing of some
attributed text. I have attempted to use both an NSText as supplied
by the NSWindow (as a field editor) and my own instance of NSTextView
but with the same (odd?) result.

When I draw the text with drawAtPoint: method of NSAttributedString
it's spacing is marginally different from when the equivalent RTF is
drawn by the NSText or NSTextView. I can see  no other way apart from
using RTF to transfer text between the NSTextView and the attributed
string. I have tried fiddling the line and paragraph spacing using
NSMutableParagraphStyle without success, since if I get the lines to
line up in one font, the line spacing is incorrect for another font.
Does anyone have any suggestions as to how one might handle this ?
How do the various apps that we see around handle this ? I have spent
many hours struggling with this and have achieved little.

Any suggestions would be appreciated.

Thanks in advance

Vincent

 _______________________________________________
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: NSAttributedString drawing and NSText drawing
      • From: Douglas Davidson <email@hidden>
    • Re: NSAttributedString drawing and NSText drawing
      • From: Joshua Scott Emmons <email@hidden>
  • Prev by Date: Re: Installer to Check to see if it's an Intel Mac
  • Next by Date: Re: Binding popup contents difficulties
  • Previous by thread: Re: Installer to Check to see if it's an Intel Mac
  • Next by thread: Re: NSAttributedString drawing and NSText drawing
  • Index(es):
    • Date
    • Thread