Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1::Grabscreenregion()
- ; Where
- ; [Name] := GAP(0.x, 0.y)
- ; 0.5 is the mid, 0 is the edge, and 1 is the furthest position
- ; for the screen region. This will make scaling for different
- ; users with differing resolutions have hopefully a more consistent exp.
- ; Using this function will attach the exact position of the cursor when activated
- ; While also saving the position in the proper formatting to the clipboard
- ; For QoL to designing actions.
- Grabscreenregion() {
- BlockInput On
- MouseGetPos, gx, gy
- WinGetPos,,, maxx, maxy
- CalcRatiox := round((gx / maxx) , 2)
- CalcRatioy := round((gy / maxy) , 2)
- clipboard := " := GAP(" CalcRatiox ", " CalcRatioy ")"
- Tooltip, "pos (%CalcRatiox%`,%CalcRatioy%) saved.", gx-50, gy-25
- SetTimer, RemoveToolTip, -5000
- BlockInput Off
- return
- RemoveToolTip:
- ToolTip
- return
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement