in reply to Re: Perl/Tk + CSSH
in thread Perl/Tk + CSSH
Ok, So I had the chance to review and here is what I have come up with. I took your example and mashed a chunk of my code that has my CSSH call, to see if I could manage the windows via example code.
#!/usr/bin/perl -w use warnings; use strict; use Tk; my ($x,$y,$count) = (0,0,0); my @systems = qw(system1 system2 system3 system4 system5 system7); foreach(@systems) { $count++; if (fork == 0) { #$widget->geometry("wxh+x+y") my $top = new MainWindow; $top->geometry('100x100'.'+'.$x.'+'.$y); $top => "cssh -G -T 'OOPCSSH' -l username $_"; ##MY PROBLEM LIES H +ERE. If I simply `the command/call` it runs but still no placement co +ntrol. $top->Button(-command => sub { warn "top$_" })->pack; MainLoop; CORE::exit(); } if( $count % 3 == 0) {$y += 150; $x = 0 } $x += 150; } MainLoop;
Since I am calling cssh, what it is actually doing is opening up a seperate XTERM window for each connection in which I can control each window with one control window. Essentially calling a seperate program all together, your example actually cleared up a previous issue I had but not quite this one, as I still cannot control the placement of the "outside" program/call. I would like to be able to place the XTERM windows that CSSH opens or use a CSSH module to do the work inside the program. Checking CPAN I didn't see what I was looking for.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Perl/Tk + CSSH
by zentara (Cardinal) on Feb 08, 2012 at 10:37 UTC |