Mouse position: Difference between revisions

Content added Content deleted
No edit summary
Line 770: Line 770:
<lang lingo>put _mouse.mouseLoc
<lang lingo>put _mouse.mouseLoc
-- point(310, 199)</lang>
-- point(310, 199)</lang>

=={{header|LiveCode}}==
<lang liveCode>
-- Method 1:
-- this script in either the Stack Script or the Card Script to get position relative to the "current window"
on mouseMove pMouseH,pMouseV
put pMouseH,pMouse
end mouseMove
-- Method 2:
-- this script can go anywhere and position relative to the "current window"
put mouseLoc()
-- Method 3:
-- this script can go anywhere and position relative to the "current window"
put the mouseLoc -- "
-- Method 4:
-- this script can go anywhere and position relative to the "current window"
put the mouseH &","& the mouseV

To get the mousePosition relative to the current screen instead of relative to the current stack window use the screenMouseLoc keyword
example results:
117,394 -- relative to current window
117,394 -- relative to current window
117,394 -- relative to current window
148,521 -- relative to current screen

</lang>


=={{header|Logo}}==
=={{header|Logo}}==