NSTextFinder guide
NSTextFinder guide
- Subject: NSTextFinder guide
- From: Daryle Walker <email@hidden>
- Date: Mon, 20 Mar 2017 07:49:56 -0400
Now I’m looking into adding find support to my window. My window is divided into two halves: a NSTableView and a NSTextView. The two views are in separate tabs, so you can’t see them at the same time. Also, I sometimes have the text-view inactive. (When it’s inactive, you can’t click the text view’s tab. In fact, if the inactivation happens while the text view is shown, I immediately switch to the table view.)
Is it possible for a find-next from the table view’s last location to jump to the text view’s first location whenever the text view is active? And jump from the text view's last find to the table view’s first find when wraparound is on? (Not automatic, but some sort of delegate call so I can switch tabs and trigger the other view’s find.) I’m on the fence whether this is a good user interaction, though (like what happens if the other view has no matches). No matter which way I go, I need the two views’ bar's search strings and other search settings to always be the same, since they are supposed to be parts of the same document. Of course, switching one view’s search bar on/off should do the same to the other view’s bar.
Is there an official guide for this class (besides Apple’s class definition page)? Or is there a cool guide on a seasoned developer’s blog (or here)?
—
Daryle Walker
Mac, Internet, and Video Game Junkie
darylew AT mac DOT com
_______________________________________________
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