• 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: NSTokenField, how to query the selection?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTokenField, how to query the selection?


  • Subject: Re: NSTokenField, how to query the selection?
  • From: Nick Zitzmann <email@hidden>
  • Date: Tue, 2 May 2006 15:08:18 -0600


On May 2, 2006, at 2:57 PM, Tim Gogolin wrote:

So I guess I've solved my problem... but there's a reason people don't document some interfaces... Sigh.
Does anyone know a better supported way to do this?

If -fieldEditor:forObject: didn't work, then there probably isn't any other documented way. The only way to obtain the selected range of some text is to query its field editor, and NSTokenField uses a private field editor class called NSTokenTextView. I was hoping the NSWindow method would return it, but if it doesn't, then you may have to acquire the selection the unofficial way (although I'd recommend using -respondsToSelector: so you minimize breakage). Better yet, file a bug report asking that NSTokenTextView be made public.


Nick Zitzmann
<http://www.chronosnet.com/>


_______________________________________________ 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
References: 
 >NSTokenField, how to query the selection? (From: Tim Gogolin <email@hidden>)
 >Re: NSTokenField, how to query the selection? (From: Nick Zitzmann <email@hidden>)
 >Re: NSTokenField, how to query the selection? (From: Tim Gogolin <email@hidden>)

  • Prev by Date: Re: NSString intValue
  • Next by Date: can't get DOMDocument from WebView
  • Previous by thread: Re: NSTokenField, how to query the selection?
  • Next by thread: NSString intValue
  • Index(es):
    • Date
    • Thread