Re: Beginner's scripting Terminal questions
Re: Beginner's scripting Terminal questions
- Subject: Re: Beginner's scripting Terminal questions
- From: Andrew Oliver <email@hidden>
- Date: Tue, 01 Mar 2005 10:55:21 -0800
On 3/1/05 10:36 AM, "Jamie Kahn Genet" <email@hidden> wrote:
> My trouble is as mentioned above: I don't get the full set of info in
> the title bar either way and I lose transparency in the Terminal window
> that opens. Can someone please tell me if there's a way to get my
> desired results? Am I able to set window colours within the Terminal? If
> so I'll just write a .command terminal script that includes them. Is
> there a way?
Despite the dictionary's implication that 'background color' takes a string
parameter you can actually pass it a quartet of 0..65535 values indicating
{R, G, B, Alpha} values:
tell application "Terminal"
set background color of window 1 to {65535, 65535, 65535, 0}
end tell
The above code creates a completely transparent window (actually, any value
in the first three octets will do this since the alpha/transparency value is
0 meaning fully transparent).
Passing 32767 as the alpha value will give a 50% transparent window, and any
other value will give the corresponding level of transparency up to 65535
which is fully opaque.
You can also set the window title using its 'custom title' property:
tell application "Terminal"
set custom title of window 1 to "blah de blah de blah"
end tell
Andrew
:)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden