I am drowning a bit here…
I just want a robust way to place the cursor in message body of a forwarded message in Mail.app. Can I achieve that using GUI-scripting (rather than sending tab keyboard events)? I executed this script:
tell application "System Events"
tell process "Mail"
activate
delay 1
get UI elements of UI element 1 of scroll area 1 of group 1 of group 1 of window 1
end tell
end tell
(I had a forwarded message open when I executed this)
and got dozens upon dozens elements in return. Which one is right? How do I place the cursor there (so I can paste from the clipboard, which seems to be the only sensible way to insert text into a mail message).