kayl has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl #DESCRIPTION DialogBox seems to ignore the positioning portion of the +geometry specification. Is there another way to position the DialogBo +x? #ERROR MESSAGE There isn't one. #PLATFORM Windows XP, SP2, ActiveState's Perl v5.8.7 for Windows use Tk; use Tk::Dialog; use strict; use warnings; my $mw = MainWindow->new; $mw->geometry('400x200+10+10'); $mw->Button ( -text=> 'DialogBox', -command=> sub { for my $i (1..10) { my $db = $mw->DialogBox(-title => 'title', -buttons => ['OK', 'Can +cel'], -default_button => 'Ok'); $mw->geometry(sprintf ("%dx%d+%d+%d", 400-$i*10, 200+$i*10, 10+$i* +10, 10+$i*10 )); $db->geometry(sprintf ("%dx%d+%d+%d", 300+$i*10, 300-$i*10, 30+$i* +10, 30+$i*10 )); $db->Show(); } } )->pack (); MainLoop;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: TK::Dialogbox geometry spec
by Anonymous Monk on Jul 08, 2008 at 21:53 UTC | |
by kayl (Initiate) on Jul 08, 2008 at 23:48 UTC | |
|
Re: TK::Dialogbox geometry spec
by zentara (Cardinal) on Jul 09, 2008 at 11:51 UTC | |
by kayl (Initiate) on Jul 09, 2008 at 20:00 UTC | |
by zentara (Cardinal) on Jul 09, 2008 at 20:17 UTC |