Re: Text Capture in Cocoa
Re: Text Capture in Cocoa
- Subject: Re: Text Capture in Cocoa
- From: Bill Cheeseman <email@hidden>
- Date: Fri, 16 Jun 2006 05:05:55 -0400
- Thread-topic: Text Capture in Cocoa
on 2006-06-15 8:15 PM, Yaogang Lian at email@hidden wrote:
> The accessibility API is quite useful for grabbing info from UI
> elements, but it seems to
> be unable to grab a single word. For example, when I point the mouse
> to a word
> in a web page, the accessibility API returns either all the texts in
> a paragraph or selected
> texts. I hope to be able to grab a single word without actually
> selecting it. This seems to
> be a more tricky task.
Using the accessibility API's "parameterized" text attributes, you should be
able to get the text under the mouse and then parse it down to the word
under the mouse.
--
Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com
PreFab Software - http://www.prefab.com/scripting.html
The AppleScript Sourcebook - http://www.AppleScriptSourcebook.com
Vermont Recipes - http://www.stepwise.com/Articles/VermontRecipes
_______________________________________________
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