Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

pudge (1)

  (email not shown publicly)
AOL IM: Crimethnk (Add Buddy, Send Message)

I run this joint, see?

Journal of pudge (1)

Thursday October 30, 2003
05:27 PM

Stupid Mac::Glue Tricks

[ #15481 ]

I have my PowerBook sometimes connected to an external monitor. When MacCvsX leaves a window on the external monitor, it keeps it offscreen, whereas most applications will put the windows on the current monitor (or make it easy to arrange them on the current monitor). So I lose the Console Window forever, unless I can hook it up to a monitor, or ...

use Mac::Glue;
my $cvs = new Mac::Glue "MacCvsX";
my $bounds = $cvs->prop(bounds => window => "Console Window");
my $d = $bounds->get;
$bounds->set(to => [20, 100,
    $d->[2] - ($d->[0] - 20),
    $d->[3] - ($d->[1] - 100)

(Requires most recent Mac::AppleEvents::Simple, v1.07.)

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.