Sublime Forum

Moving/resizing windows via keyboard shortcut

#1

Hi guys. Is there a way (see subject)?
I’m on OSX and I tried with AppleScript. osascript works decently
from within plugins, however the following

def move_window():
os.system('osascript -e ‘tell app “System Events” to tell application process “Sublime Text 2”’ -e 'set position of window 1 to ’ + ‘{20,20}’ + ’ ’ -e ‘end tell’ ')

gives me a spinning beachball for a second or so and then nothing.

Anyone knows why this script does not work?
Anyone has an alternative solution?

Thanks
Piero

0 Likes

#2

Don’t know if this will give you the control you want, but you could try something like ShiftIt. Not a ST specific thing, but may do what you want.

0 Likes

#3

Thx for your suggestion. I think I will use slate, still I’m curious about
what is wrong.
Piero

0 Likes