I know that it can be done in obj-c but I can’t seem to find any examples of how to do it in applescript.
Normal co-ordinates go x,y y being the bottom and x being left
I want y to be the top and x to be the left.
I want to flip it on a box and/or a scroll view.
Anyone know how?
Which version of Studio/OS X are you using?
Tiger (OS X v10.4; Studio v1.4) users may be interested in the “New Coordinate System Support” section of the Studio release notes.
It’s also here in the AppleScript Studio Terminology Reference.
If you don’t have 10.4, then I guess you can use something like this to translate the coordinates, but you must know beforehand the height of the parent view:
on flipPointCoordinates(xLeft, yBottom, height)
return {xLeft, height - yBottom}
end flipPointCoordinates