Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Maximise or minimise Perl/Tk Main Window

by dree (Monsignor)
on Sep 18, 2002 at 11:51 UTC ( [id://198799]=note: print w/replies, xml ) Need Help??


in reply to Maximise or minimise Perl/Tk Main Window

What do you mean for "minimize" ? Iconify? If yes, try this:
use strict; use Tk; my $mw = new MainWindow; $mw->Frame(-width=>200, height =>25); $mw->Button(-text => "Maximize", -command => sub {$mw->geometry($mw->screenwidth . "x" . $mw->s +creenheight . "+0+0")}) ->pack(); $mw->Button(-text => "Minimize", -command => sub {$mw->iconify;}) ->pack(); $mw->Button(-text => "Close", -command => sub {exit;}) ->pack(); MainLoop;
You can try perldoc Tk::Wm

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://198799]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2024-03-29 12:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found