AXTextMarkerForPosition broken in Safari 5.1
AXTextMarkerForPosition broken in Safari 5.1
- Subject: AXTextMarkerForPosition broken in Safari 5.1
- From: Michael Ash <email@hidden>
- Date: Sun, 07 Aug 2011 17:40:04 -0400
Folks,
I have an app that needs to get the text at the location of the mouse cursor in a way that I can tell which word the mouse is over. Naturally, Accessibility works well for this. Unfortunately, I never found a good way to get text out of Safari (and other WebView-using apps) other than using the private AXTextMarkerForPosition parameterized attribute. This attribute worked fine until 5.1, where it now appears to be broken. In my testing, it almost always returns a text marker that corresponds to the upper left corner of the visible area of the view, rather than one that corresponds to where the mouse cursor is.
Incidentally, the built-in cmd-control-d dictionary lookup on 10.6 uses this attribute and is also broken by this problem.
I've filed a bug with Apple which includes a sample app. I've put the bug on Open Radar as well here:
http://www.openradar.me/radar?id=1288408
If anyone from Apple is here, it's rdar://9911657
I would very much appreciate any guidance on this matter. If anyone knows when a fix might be available, that would be great to know. If anyone knows an alternate way of accomplishing what I need to do, that would also be great.
--
Pilot: T/C ball seemed stuck in the middle during my last turn.
Mechanic: Congratulations! You've just made your first coordinated turn.
Mike Ash - <http://www.mikeash.com/>, <mailto:email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Accessibility-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden