• 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: Keeping track of new user selections in NSTextView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Keeping track of new user selections in NSTextView


  • Subject: Re: Keeping track of new user selections in NSTextView
  • From: Antonio Nunes <email@hidden>
  • Date: Sat, 1 Jul 2006 12:16:24 +0100


On 1 Jul 2006, at 11:53, email@hidden wrote:

I'm looking for a method in NSTextView
that gets triggered exactly when the user selects a portion of text
[...] It seems that there always is
a "default" selection even when the user has actually selected nothing. So
where is the method I need ?

Checking the range of the selection will tell you whether the selection is extended or not. Check the "selectedRanges" method of the NSTextView to decide whether you need to process the notification. (The notification will still be triggered every time the text is modified though.)


HTH,
António

-----------------------------------------------------------
What you have inside you expresses itself through both your
choice of words and the level of energy you assign to them.
The more healed, whole and connected you feel inside,
the more healing your words will be.

--Rita Goswami
-----------------------------------------------------------


_______________________________________________ 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: 
 >Keeping track of new user selections in NSTextView (From: email@hidden)

  • Prev by Date: Keeping track of new user selections in NSTextView
  • Next by Date: Re: Compositing to custom view in Cocoa
  • Previous by thread: Keeping track of new user selections in NSTextView
  • Next by thread: Re: Compositing to custom view in Cocoa
  • Index(es):
    • Date
    • Thread