Thread Tabelle mit Rahmen und row/colspan (6 answers)
Opened by TheBigfoot at 2007-10-15 16:01

ptk
 2007-10-16 00:43
#100887 #100887
User since
2003-11-28
3645 Artikel
ModeratorIn
[default_avatar]
Einen Rahmen könnte man mit grid bestimmt faken. Z.B. mit schmalen schwarzen Frames oder mit Labels mit border.
Code: (dl )
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
27
28
29
use Tk;

$top = new MainWindow;

$top->optionAdd("*HBorder.height", 1);
$top->optionAdd("*HBorder.background", "black");

$top->optionAdd("*VBorder.width", 1);
$top->optionAdd("*VBorder.background", "black");

for (1..20) {
Tk::grid(
$top->Label(-text => "Hallo"),
$top->Frame(-class => "VBorder"),
$top->Label(-text => "Welt"),
-sticky => "ns",
);
Tk::grid(
$top->Frame(-class => "HBorder"),
$top->Frame(-class => "HBorder"),
$top->Frame(-class => "HBorder"),
-sticky => "ew",
);
}


MainLoop;

__END__

Code: (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use Tk;

$top = new MainWindow;

$top->optionAdd("*Label.borderWidth", 1);
$top->optionAdd("*Label.relief", "solid");

for (1..20) {
Tk::grid(
$top->Label(-text => "Hallo"),
$top->Label(-text => "Welt"),
);
}

$top->WidgetDump;
MainLoop;

__END__

View full thread Tabelle mit Rahmen und row/colspan