0
votes

How is it possible to get the coordinates of the current text input globally? I am familiar with Quartz Event Taps and NSEvent API for monitoring events, but I have not yet found a way to figure out where on the screen text input is occurring. Is there an API I am missing?

1

1 Answers

0
votes

You can try the Accessibility API.

Take a look at AXUIElementCopyAttributeValue(... kAXFocusedUIElementAttribute ...)

Once you have the focused element, you can grab screen coordinates from it.