• 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: Placing an image in the border of NSTextView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Placing an image in the border of NSTextView


  • Subject: Re: Placing an image in the border of NSTextView
  • From: Martin Wierschin <email@hidden>
  • Date: Wed, 24 Jun 2009 16:04:39 -0700

How can I place an image in the left border of an NSTextView, without causing a move or shift of the text to the right?

May I suggest learning about the Cocoa text system?

There's nothing in there that will do what he wants. Any image one adds via the Cocoa text system is going to be a character/inline graphic, which has a size that displaces the surrounding text. That said, that documentation will be a great help when trying to figure out how to position an image.


It's better for Filip to search the list archives for displaying ancillary things in a text view, like line numbers in the gutter. Depending on what you're doing exactly, you may want to subclass NSTextView to do your additional drawing.

~Martin


_______________________________________________

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: 
 >Placing an image in the border of NSTextView (From: Filip van der Meeren <email@hidden>)
 >Re: Placing an image in the border of NSTextView (From: Kyle Sluder <email@hidden>)

  • Prev by Date: IBPlugin embedding question
  • Next by Date: Re: IBPlugin embedding question
  • Previous by thread: Re: Placing an image in the border of NSTextView
  • Next by thread: QTMovieView - control-click vs. right-click give different behavior?
  • Index(es):
    • Date
    • Thread