Leser: 1
3 Einträge, 1 Seite |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/perl
use strict;
use warnings;
use Tk;
my $top = MainWindow->new();
my $frame1 = $top->Frame(-width => 200,
-height => 50,
-bg => 'black');
my $frame2 = $top->Frame(-width => 200,
-height => 50,
-bg => 'red');
my $frame3 = $top->Frame(-width => 200,
-height => 50,
-bg => 'yellow');
$frame1->pack(-side => 'top');
$frame2->pack(-side => 'top');
$frame3->pack(-side => 'top');
MainLoop();
1
2
3
4
# ...
$frame1->pack(-side => 'top', -fill => 'both');
$frame2->pack(-side => 'top', -fill => 'both');
$frame3->pack(-side => 'top', -fill => 'both');
1
2
3
4
# ...
$frame1->pack(-side => 'top', -fill => 'both', -expand => 1);
$frame2->pack(-side => 'top', -fill => 'both', -expand => 1);
$frame3->pack(-side => 'top', -fill => 'both', -expand => 1);
3 Einträge, 1 Seite |