File: tframe

package info (click to toggle)
libtk-gbarr-perl 2.08-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 284 kB
  • sloc: perl: 1,875; makefile: 19
file content (27 lines) | stat: -rw-r--r-- 561 bytes parent folder | download | duplicates (7)
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
# A Titled Frame widget.
#!/usr/local/bin/perl -w
use strict;
use Tk;
use Tk::TFrame;

my $mw = Tk::MainWindow->new;

my $frame = $mw->TFrame(
	-label => [
		-text => 'Title',
		-borderwidth => 2,
		-relief => 'groove'
	],
	-borderwidth => 2,
	-relief => 'groove'
);

$frame->Label(-text => 'Left')->pack(-side => 'left');
$frame->Label(-text => 'Right')->pack(-side => 'right');
$frame->Label(-text => 'Top')->pack(-side => 'top');
$frame->Label(-text => 'Bottom')->pack(-side => 'bottom');

$frame->pack(-fill => 'both', -expand => 1);

Tk::MainLoop;
__END__