ryyst
ryyst

Reputation: 9801

Mac OS X - programmatically resize windows

I'd like to know how apps like Divvy, Cinch, SizeUp, etc. resize / move windows belonging to other applications? I know that this might involve private APIs. Or do they all use AppleScript? Are there any resources out there about how to do it?

Upvotes: 6

Views: 1560

Answers (1)

Jeff Kelley
Jeff Kelley

Reputation: 19071

A while back I wrote about using AppleScript to do just that. Basically, do the following:

tell application "MyApp"
    set the bounds of the first window to {x, y, width, height}
end tell

Upvotes: 7

Related Questions