Commit | Line | Data |
---|---|---|
86530b38 AT |
1 | # Copyright (c) 1995-1999 Nick Ing-Simmons. All rights reserved. |
2 | # This program is free software; you can redistribute it and/or | |
3 | # modify it under the same terms as Perl itself. | |
4 | ||
5 | package Tk::LabEntry; | |
6 | ||
7 | use vars qw($VERSION); | |
8 | $VERSION = '3.011'; # $Id: //depot/Tk8/Tk/LabEntry.pm#11 $ | |
9 | ||
10 | use base qw(Tk::Frame); | |
11 | use Tk::widgets qw(Frame Label Entry); | |
12 | ||
13 | Construct Tk::Widget 'LabEntry'; | |
14 | ||
15 | sub Populate | |
16 | { | |
17 | require Tk::Entry; | |
18 | # LabeledEntry constructor. | |
19 | # | |
20 | my($cw, $args) = @_; | |
21 | $cw->SUPER::Populate($args); | |
22 | # Advertised subwidgets: entry. | |
23 | my $e = $cw->Entry(); | |
24 | $e->pack('-expand' => 1, '-fill' => 'both'); | |
25 | $cw->Advertise('entry' => $e ); | |
26 | $cw->ConfigSpecs(DEFAULT => [$e]); | |
27 | $cw->Delegates(DEFAULT => $e); | |
28 | $cw->AddScrollbars($e) if (exists $args->{-scrollbars}); | |
29 | } | |
30 | ||
31 | 1; |