• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Setting bounds in Terminal
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Setting bounds in Terminal


  • Subject: Setting bounds in Terminal
  • From: Robert Poland <email@hidden>
  • Date: Sun, 16 Jan 2011 10:26:21 -0700

Hi,

OS 10.6.6.

I am trying to set the bounds of a window in terminal.

The following script seems to imply that it can't be done correctly. The newT and newB get screwed up.

From an email if 2005 running multiple times was supposed to make it work. Doesn't seem to make any difference.

Juggling the newT and newB values give weird results.

tell application "Terminal"
	set x to 0 -- initialize
	set newL to 800
	set newT to 200
	set newR to 1400
	set newB to 1400

	repeat 100 times --while x ≠‚ newT
		set bounds of front window to {newL, newT, newR, newB}
		set {w, x, y, z} to bounds of window 1
		if x = newT then exit repeat
	end repeat
end tell
{w, x, y, z} -- gives answer of {800, 22, 1400, 1222}

Is there a cure?


Robert Poland - Fort Collins, CO



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Setting bounds in Terminal
      • From: Christopher Stone <email@hidden>
    • Re: Setting bounds in Terminal
      • From: Axel Luttgens <email@hidden>
  • Prev by Date: Re: Script Modification
  • Next by Date: Re: Top-posting [ was Variable names]
  • Previous by thread: Re: A Subtle Error
  • Next by thread: Re: Setting bounds in Terminal
  • Index(es):
    • Date
    • Thread