views:

27

answers:

1

Hi all, this is my first post, wish your help.

In Mac OS (10.5 or 10.6), I want to find the element at the specified coordinate in screen.

If you have ever used UIElementInspector, you will konw exactly what I mean. Move mouse cursor around with UIElementInspector running, you will get a detail description, which is what I want, about the element under the mouse cursor.

I know Applescript is powerful enough to do many things, and we can add additions to it to fit some special needs. Extention can be performed using Object-C, Python, perl, etc.

And since UIElementInspector is implemented and provided in Mac OS 10.6, there must be ways to realize my requirement.

Any language, any implementation will be helpful.

Any help will be apriciate.

A: 

You won't be able to do this in applescript. There's the problem of getting the mouse coordinates and the problem of knowing which application to ask for its UI Elements. You mentioned UIElementInspector... apple provides the source code for that so just download it and study it.

regulus6633
Thanks a lot, regulus6633.I will try finding some useful snippets out, although it seams a little painful for me to review codes of others.