Linux web0273.sh.tyo1 4.18.0-553.141.2.lve.el7h.x86_64 #1 SMP Wed Jul 8 17:20:31 UTC 2026 x86_64
Apache
: 127.0.0.1 | : 216.73.216.151
Cant Read [ /etc/named.conf ]
8.3.31
r2745769
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
README
+ Create Folder
+ Create File
/
lib64 /
perl5 /
vendor_perl /
Tk /
[ HOME SHELL ]
Name
Size
Permission
Action
DragDrop
[ DIR ]
drwxr-xr-x
Event
[ DIR ]
drwxr-xr-x
Menu
[ DIR ]
drwxr-xr-x
TableMatrix
[ DIR ]
drwxr-xr-x
Text
[ DIR ]
drwxr-xr-x
pTk
[ DIR ]
drwxr-xr-x
804delta.pod
2.65
KB
-rw-r--r--
Adjuster.pm
10.91
KB
-rw-r--r--
Adjuster.pod
6.92
KB
-rw-r--r--
After.pm
1.9
KB
-rw-r--r--
Animation.pm
4.91
KB
-rw-r--r--
Animation.pod
2.84
KB
-rw-r--r--
Balloon.pm
20.7
KB
-rw-r--r--
Balloon.pod
9.96
KB
-rw-r--r--
Bitmap.pm
225
B
-rw-r--r--
Bitmap.pod
2.88
KB
-rw-r--r--
BrowseEntry.pm
13.32
KB
-rw-r--r--
BrowseEntry.pod
5.07
KB
-rw-r--r--
Button.pm
5.95
KB
-rw-r--r--
Button.pod
7.62
KB
-rw-r--r--
Camel.xpm
1.3
KB
-rw-r--r--
Canvas.pm
28.22
KB
-rw-r--r--
Canvas.pod
86.71
KB
-rw-r--r--
Checkbutton.pm
997
B
-rw-r--r--
Checkbutton.pod
11.08
KB
-rw-r--r--
Clipboard.pm
1.83
KB
-rw-r--r--
Clipboard.pod
2.83
KB
-rw-r--r--
CmdLine.pm
15.82
KB
-rw-r--r--
CmdLine.pod
14.12
KB
-rw-r--r--
ColorEdit.xpm
2.62
KB
-rw-r--r--
ColorEditor.pm
22.8
KB
-rw-r--r--
ColorEditor.pod
3.67
KB
-rw-r--r--
Common.pod
266
B
-rw-r--r--
Compound.pm
712
B
-rw-r--r--
Compound.pod
8.61
KB
-rw-r--r--
Config.pm
414
B
-rw-r--r--
ConfigSpecs.pod
7.94
KB
-rw-r--r--
Configure.pm
1.21
KB
-rw-r--r--
Credits
149
B
-rw-r--r--
DItem.pod
11.98
KB
-rw-r--r--
Derived.pm
11.83
KB
-rw-r--r--
Derived.pod
2.2
KB
-rw-r--r--
Dialog.pm
1.66
KB
-rw-r--r--
Dialog.pod
2.82
KB
-rw-r--r--
DialogBox.pm
4.54
KB
-rw-r--r--
DialogBox.pod
4.39
KB
-rw-r--r--
DirTree.pm
6.47
KB
-rw-r--r--
DirTree.pod
4.14
KB
-rw-r--r--
Dirlist.pm
1.89
KB
-rw-r--r--
DragDrop.pm
7.18
KB
-rw-r--r--
DropSite.pm
4.96
KB
-rw-r--r--
DropSite.pod
641
B
-rw-r--r--
DummyEncode.pm
729
B
-rw-r--r--
English.pm
9.63
KB
-rw-r--r--
Entry.pm
15.56
KB
-rw-r--r--
Entry.pod
22.23
KB
-rw-r--r--
Error.pod
4.98
KB
-rw-r--r--
ErrorDialog.pm
3.39
KB
-rw-r--r--
Event.pm
458
B
-rw-r--r--
Eventloop.pod
1.18
KB
-rw-r--r--
FBox.pm
29.84
KB
-rw-r--r--
FBox.pod
1.59
KB
-rw-r--r--
FileSelect.pm
14.76
KB
-rw-r--r--
FileSelect.pod
4.44
KB
-rw-r--r--
FloatEntry.pm
1.99
KB
-rw-r--r--
Font.pm
2.8
KB
-rw-r--r--
Font.pod
15.2
KB
-rw-r--r--
Frame.pm
7.99
KB
-rw-r--r--
Frame.pod
3.99
KB
-rw-r--r--
HList.pm
13.34
KB
-rw-r--r--
HList.pod
35.38
KB
-rw-r--r--
IO.pm
2.97
KB
-rw-r--r--
IO.pod
1.21
KB
-rw-r--r--
IconList.pm
19.2
KB
-rw-r--r--
IconList.pod
1.36
KB
-rw-r--r--
Image.pm
1.48
KB
-rw-r--r--
Image.pod
4.07
KB
-rw-r--r--
InputO.pm
275
B
-rw-r--r--
InputO.pod
1.27
KB
-rw-r--r--
Internals.pod
5.62
KB
-rw-r--r--
ItemStyle.pm
703
B
-rw-r--r--
JPEG.pm
926
B
-rw-r--r--
LabEntry.pm
773
B
-rw-r--r--
LabFrame.pm
3.47
KB
-rw-r--r--
LabFrame.pod
2.34
KB
-rw-r--r--
LabRadio.pm
1.6
KB
-rw-r--r--
Label.pm
386
B
-rw-r--r--
Label.pod
3.57
KB
-rw-r--r--
Labelframe.pm
292
B
-rw-r--r--
Labelframe.pod
5.87
KB
-rw-r--r--
Listbox.pm
22.07
KB
-rw-r--r--
Listbox.pod
26.01
KB
-rw-r--r--
MMtry.pm
1.61
KB
-rw-r--r--
MMutil.pm
13.13
KB
-rw-r--r--
MainWindow.pm
5.6
KB
-rw-r--r--
MainWindow.pod
2.2
KB
-rw-r--r--
MakeDepend.pm
5.52
KB
-rw-r--r--
Menu.pm
29.71
KB
-rw-r--r--
Menu.pod
32.08
KB
-rw-r--r--
Menubar.pm
382
B
-rw-r--r--
Menubutton.pm
10.66
KB
-rw-r--r--
Menubutton.pod
8.16
KB
-rw-r--r--
Message.pm
419
B
-rw-r--r--
Message.pod
5.13
KB
-rw-r--r--
MsgBox.pm
18.05
KB
-rw-r--r--
MsgBox.pod
1.48
KB
-rw-r--r--
Mwm.pm
311
B
-rw-r--r--
Mwm.pod
3.28
KB
-rw-r--r--
NBFrame.pm
368
B
-rw-r--r--
NoteBook.pm
10.27
KB
-rw-r--r--
NoteBook.pod
5.75
KB
-rw-r--r--
Optionmenu.pm
2.9
KB
-rw-r--r--
Optionmenu.pod
1.94
KB
-rw-r--r--
PNG.pm
726
B
-rw-r--r--
Pane.pm
12.9
KB
-rw-r--r--
Panedwindow.pm
5.03
KB
-rw-r--r--
Panedwindow.pod
10.56
KB
-rw-r--r--
Photo.pm
415
B
-rw-r--r--
Photo.pod
18.08
KB
-rw-r--r--
Pixmap.pm
266
B
-rw-r--r--
Pixmap.pod
1.81
KB
-rw-r--r--
Popup.pod
3.07
KB
-rw-r--r--
Pretty.pm
1.74
KB
-rw-r--r--
ProgressBar.pm
11.52
KB
-rw-r--r--
README.Adjust
3.28
KB
-rw-r--r--
ROText.pm
1.06
KB
-rw-r--r--
ROText.pod
725
B
-rw-r--r--
Radiobutton.pm
1.03
KB
-rw-r--r--
Radiobutton.pod
10.69
KB
-rw-r--r--
Region.pm
2.95
KB
-rw-r--r--
Reindex.pm
5.19
KB
-rw-r--r--
ReindexedROText.pm
255
B
-rw-r--r--
ReindexedText.pm
245
B
-rw-r--r--
Scale.pm
6.68
KB
-rw-r--r--
Scale.pod
10.05
KB
-rw-r--r--
Scrollbar.pm
9.97
KB
-rw-r--r--
Scrollbar.pod
13.71
KB
-rw-r--r--
Scrolled.pod
1.86
KB
-rw-r--r--
Spinbox.pm
2.26
KB
-rw-r--r--
Spinbox.pod
25.74
KB
-rw-r--r--
Stats.pm
407
B
-rw-r--r--
Submethods.pm
744
B
-rw-r--r--
Submethods.pod
662
B
-rw-r--r--
SunConst.pod
405
B
-rw-r--r--
TList.pm
7.1
KB
-rw-r--r--
TList.pod
18.48
KB
-rw-r--r--
Table.pm
11.69
KB
-rw-r--r--
Table.pod
2.41
KB
-rw-r--r--
TableMatrix.pm
26.1
KB
-rw-r--r--
TableMatrix.pod
56.32
KB
-rw-r--r--
Tcl-perl.pod
5.16
KB
-rw-r--r--
Text.pm
43.07
KB
-rw-r--r--
Text.pod
79.41
KB
-rw-r--r--
TextEdit.pm
14.06
KB
-rw-r--r--
TextList.pm
25.78
KB
-rw-r--r--
TextUndo.pm
24.76
KB
-rw-r--r--
TextUndo.pod
1.59
KB
-rw-r--r--
Tiler.pm
4.07
KB
-rw-r--r--
Tiler.pod
689
B
-rw-r--r--
TixGrid.pm
28.23
KB
-rw-r--r--
TixGrid.pod
15.77
KB
-rw-r--r--
Tk.xbm
3.07
KB
-rw-r--r--
Tk.xpm
1.29
KB
-rw-r--r--
TkXSUB.def
3.09
KB
-rw-r--r--
Toplevel.pm
5.15
KB
-rw-r--r--
Toplevel.pod
5.66
KB
-rw-r--r--
Trace.pm
12.21
KB
-rw-r--r--
Tree.pm
5.9
KB
-rw-r--r--
Tree.pod
7.87
KB
-rw-r--r--
UserGuide.pod
19.43
KB
-rw-r--r--
Widget.pm
42.71
KB
-rw-r--r--
Widget.pod
25.06
KB
-rw-r--r--
WidgetDemo.pod
1.7
KB
-rw-r--r--
WinPhoto.pm
1.28
KB
-rw-r--r--
Wm.pm
3.75
KB
-rw-r--r--
Wm.pod
29.5
KB
-rw-r--r--
X.pm
5.73
KB
-rw-r--r--
X.pod
5.37
KB
-rw-r--r--
X11Font.pm
3.04
KB
-rw-r--r--
X11Font.pod
1.6
KB
-rw-r--r--
Xcamel.gif
4.09
KB
-rw-r--r--
Xlib.pm
276
B
-rw-r--r--
Xrm.pm
121
B
-rw-r--r--
Xrm.pod
1.06
KB
-rw-r--r--
act_folder.xbm
227
B
-rw-r--r--
act_folder.xpm
438
B
-rw-r--r--
after.pod
6
KB
-rw-r--r--
anim.gif
2.47
KB
-rw-r--r--
arrowdownwin.xbm
234
B
-rw-r--r--
balArrow.xbm
123
B
-rw-r--r--
bind.pod
21.88
KB
-rw-r--r--
bindtags.pod
4.09
KB
-rw-r--r--
callbacks.pod
2.91
KB
-rw-r--r--
cbxarrow.xbm
263
B
-rw-r--r--
chooseColor.pod
1.81
KB
-rw-r--r--
chooseDirectory.pod
2.79
KB
-rw-r--r--
composite.pod
5.01
KB
-rw-r--r--
event.pod
14.93
KB
-rw-r--r--
exit.pod
974
B
-rw-r--r--
file.xbm
233
B
-rw-r--r--
file.xpm
298
B
-rw-r--r--
fileevent.pod
4.61
KB
-rw-r--r--
focus.pod
6.22
KB
-rw-r--r--
folder.xbm
215
B
-rw-r--r--
folder.xpm
414
B
-rw-r--r--
form.pod
13.05
KB
-rw-r--r--
getOpenFile.pod
6.86
KB
-rw-r--r--
grab.pod
4.86
KB
-rw-r--r--
grid.pod
16.43
KB
-rw-r--r--
icon.gif
1.88
KB
-rw-r--r--
install.pm
764
B
-rw-r--r--
license.terms
1.75
KB
-rw-r--r--
mega.pod
10.61
KB
-rw-r--r--
messageBox.pod
1.89
KB
-rw-r--r--
openfile.xbm
245
B
-rw-r--r--
openfolder.xbm
227
B
-rw-r--r--
openfolder.xpm
418
B
-rw-r--r--
option.pod
8.4
KB
-rw-r--r--
options.pod
24.28
KB
-rw-r--r--
overview.pod
4.55
KB
-rw-r--r--
pTk.pod
16.81
KB
-rw-r--r--
pack.pod
10.31
KB
-rw-r--r--
palette.pod
3.3
KB
-rw-r--r--
place.pod
10.46
KB
-rw-r--r--
prolog.ps
9.32
KB
-rw-r--r--
selection.pod
6.79
KB
-rw-r--r--
send.pod
4.35
KB
-rw-r--r--
srcfile.xpm
302
B
-rw-r--r--
textfile.xpm
310
B
-rw-r--r--
tixWm.pod
1.95
KB
-rw-r--r--
tkGlue.def
2.38
KB
-rw-r--r--
tkGlue.h
2.34
KB
-rw-r--r--
tkGlue.m
1.46
KB
-rw-r--r--
tkGlue.t
2.3
KB
-rw-r--r--
tkGlue_f.h
341
B
-rw-r--r--
tkvars.pod
3.52
KB
-rw-r--r--
tranicon.gif
1.68
KB
-rw-r--r--
typemap
1.61
KB
-rw-r--r--
vtab.def
4.04
KB
-rw-r--r--
widgets.pm
309
B
-rw-r--r--
widgets.pod
286
B
-rw-r--r--
win.xbm
284
B
-rw-r--r--
winfolder.xpm
719
B
-rw-r--r--
wintext.xpm
743
B
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : Table.pm
# Copyright (c) 1995-2003 Nick Ing-Simmons. All rights reserved. # This program is free software; you can redistribute it and/or # modify it under the same terms as Perl itself. package Tk::Table; use strict; use vars qw($VERSION); $VERSION = '4.015'; # was: sprintf '4.%03d', q$Revision: #12 $ =~ /\D(\d+)\s*$/; use AutoLoader; use base qw(Tk::Frame); Construct Tk::Widget 'Table'; # Constants for QueueLayout flags sub _SlaveSize () { 1 } # Slave has asked for change of width or height sub _SlaveChange () { 2 } # We lost or gained a slave sub _ViewChange () { 4 } # xview or yview called sub _ConfigEvent () { 8 } # Table has changed size sub _ScrollBars () { 32 } # Scrollabrs came or went sub _RowColCount () { 16 } # rows or columns configured sub ClassInit { my ($class,$mw) = @_; $mw->bind($class,'<Configure>',['QueueLayout',_ConfigEvent]); $mw->bind($class,'<FocusIn>', 'NoOp'); $mw->XYscrollBind($class); return $class; } sub _view { my ($t,$s,$page,$a,$op,$num,$type) = @_; if ($op eq 'moveto') { $$s = int(@$a*$num); } else { $num *= ($page/2) if ($type eq 'pages'); $$s += $num; } $$s = 0 if ($$s < 0); $t->QueueLayout(_ViewChange); } sub xview { my $t = shift; $t->_view(\$t->{Left},$t->cget('-columns'),$t->{Width},@_); } sub yview { my $t = shift; $t->_view(\$t->{Top},$t->cget('-rows'),$t->{Height},@_); } sub FocusChildren { my $t = shift; return () if ($t->cget('-takefocus')); return $t->SUPER::FocusChildren; } sub Populate { my ($t,$args) = @_; $t->SUPER::Populate($args); $t->ConfigSpecs('-scrollbars' => [METHOD => 'scrollbars','Scrollbars','nw'], '-takefocus' => [SELF => 'takeFocus','TakeFocus',1], '-rows' => [METHOD => 'rows','Rows',10], '-fixedrows' => [METHOD => 'fixedRows','FixedRows',0], '-columns' => [METHOD => 'columns','Columns',10], '-fixedcolumns' => [METHOD => 'fixedColumn','FixedColumns',0], '-highlightthickness' => [SELF => 'highlightThickness','HighlightThickness',2] ); $t->_init; } sub sizeN { my ($n,$a) = @_; my $max = 0; my $i = 0; my $sum = 0; while ($i < @$a && $i < $n) { my $n = $a->[$i++]; $a->[$i-1] = $n = 0 unless (defined $n); $sum += $n; } $max = $sum if ($sum > $max); while ($i < @$a) { $sum = $sum-$a->[$i-$n]+$a->[$i]; $max = $sum if ($sum > $max); $i++; } return $max; } sub total { my ($a) = @_; my $total = 0; my $x; foreach $x (@{$a}) { $total += $x; } return $total; } sub constrain { my ($sb,$a,$pixels,$fixed) = @_; my $n = $$sb+$fixed; my $total = 0; my $i; $n = @$a if ($n > @$a); $n = $fixed if ($n < $fixed); for ($i= 0; $i < $fixed; $i++) { (defined($a->[$i])) && ($total += $a->[$i]); } for ($i=$n; $total < $pixels && $i < @$a; $i++) { $a->[$i] ||= 0; $total += $a->[$i]; } while ($n > $fixed) { if (($total += $a->[--$n]) > $pixels) { $n++; last; } } $$sb = $n-$fixed; } sub Layout { my ($t) = @_; return unless Tk::Exists($t); my $rows = @{$t->{Row}}; my $bw = $t->cget(-highlightthickness); my $frows = $t->cget(-fixedrows); my $fcols = $t->cget(-fixedcolumns); my $sb = $t->cget(-scrollbars); my $H = $t->Height; my $W = $t->Width; my $tadj = $bw; my $badj = $bw; my $ladj = $bw; my $radj = $bw; my @xs = ($W,0,0,0); my @ys = (0,$H,0,0); my $xsb; my $ysb; my $why = $t->{LayoutPending}; $t->{LayoutPending} = 0; if ($sb =~ /[ns]/) { $t->{xsb} = $t->Scrollbar(-orient => 'horizontal', -command => ['xview' => $t]) unless (defined $t->{xsb}); $xsb = $t->{xsb}; $t->Advertise('xscrollbar' => $xsb); $xs[3] = $xsb->ReqHeight; if ($sb =~ /n/) { $xs[1] = $tadj; $tadj += $xs[3]; } else { $badj += $xs[3]; $xs[1] = $H-$badj; } } else { $t->{xsb}->UnmapWindow if (defined $t->{xsb}); } if ($sb =~ /[ew]/) { $t->{ysb} = $t->Scrollbar(-orient => 'vertical', -command => ['yview' => $t]) unless (defined $t->{ysb}); $ysb = $t->{ysb}; $t->Advertise('yscrollbar' => $ysb); $ys[2] = $ysb->ReqWidth; if ($sb =~ /w/) { $ys[0] = $ladj; $ladj += $ys[2]; } else { $radj += $ys[2]; $ys[0] = $W-$radj; } } else { $t->{ysb}->UnmapWindow if (defined $t->{ysb}); } constrain(\$t->{Top}, $t->{Height},$H-($tadj+$badj),$frows); constrain(\$t->{Left},$t->{Width}, $W-($ladj+$radj),$fcols); my $top = $t->{Top}+$frows; my $left = $t->{Left}+$fcols; if ($why & (_ScrollBars|_RowColCount|_SlaveSize)) { # Width and/or Height of element or # number of rows and/or columns or # scrollbar presence has changed my $w = sizeN($t->cget('-columns'),$t->{Width})+$radj+$ladj; my $h = sizeN($t->cget('-rows'),$t->{Height})+$tadj+$badj; $t->GeometryRequest($w,$h); } if ($rows) { my $cols = @{$t->{Width}}; my $yhwm = $top-$frows; my $xhwm = $left-$fcols; my $y = $tadj; my $r; for ($r = 0; $r < $rows; $r++) { my $h = $t->{Height}[$r]; next unless defined $h; if (($r < $top && $r >= $frows) || ($y+$h > $H-$badj)) { if (defined $t->{Row}[$r]) { my $c; for ($c = 0; $c < @{$t->{Row}[$r]}; $c++) { my $s = $t->{Row}[$r][$c]; if (defined $s) { $s->UnmapWindow; if ($why & 1) { my $w = $t->{Width}[$c]; $s->ResizeWindow($w,$h); } } } } } else { my $hwm = $left-$fcols; my $sh = 0; my $x = $ladj; my $c; $ys[1] = $y if ($y < $ys[1] && $r >= $frows); for ($c = 0; $c <$cols; $c++) { my $s = $t->{Row}[$r][$c]; my $w = $t->{Width}[$c]; if (($c < $left && $c >= $fcols) || ($x+$w > $W-$radj) ) { if (defined $s) { $s->UnmapWindow; $s->ResizeWindow($w,$h) if ($why & 1); } } else { $xs[0] = $x if ($x < $xs[0] && $c >= $fcols); if (defined $s) { if ($why & 1) { $s->MoveResizeWindow($x,$y,$w,$h); } else { $s->MoveWindow($x,$y); } $s->MapWindow; } $x += $w; if ($c >= $fcols) { $hwm++; $sh += $w } } } $xhwm = $hwm if ($hwm > $xhwm); $xs[2] = $sh if ($sh > $xs[2]); $y += $h; if ($r >= $frows) { $ys[3] += $h; $yhwm++; } } } $t->{Bottom} = $yhwm; $t->{Right} = $xhwm; if (defined $xsb && $xs[2] > 0) { $xsb->MoveResizeWindow(@xs); $cols -= $fcols; if ($cols > 0) { $xsb->set($t->{Left}/$cols,$t->{Right}/$cols); $xsb->MapWindow; } } if (defined $ysb && $ys[3] > 0) { $ysb->MoveResizeWindow(@ys); $rows -= $frows; if ($rows > 0) { $ysb->set($t->{Top}/$rows,$t->{Bottom}/$rows); $ysb->MapWindow; } } } } sub QueueLayout { my ($m,$why) = @_; $m->afterIdle(['Layout',$m]) unless ($m->{LayoutPending}); $m->{LayoutPending} |= $why; } sub SlaveGeometryRequest { my ($m,$s) = @_; my ($row,$col) = @{$m->{Slave}{$s->PathName}}; my $sw = $s->ReqWidth; my $sh = $s->ReqHeight; my $sz = 0; if ($sw > $m->{Width}[$col]) { $m->{Width}[$col] = $sw; $m->QueueLayout(_SlaveSize); $sz++; } if ( (not defined ($m->{Height}[$row])) or $sh > $m->{Height}[$row]) { $m->{Height}[$row] = $sh; $m->QueueLayout(_SlaveSize); $sz++; } if (!$sz) { $s->ResizeWindow($m->{Width}[$col],$m->{Height}[$row]); } } sub get { my ($t,$row,$col) = @_; return $t->{Row}[$row][$col]; } sub LostSlave { my ($t,$s) = @_; my $info = delete $t->{Slave}{$s->PathName}; if (defined $info) { my ($row,$col) = @$info; $t->{Row}[$row][$col] = undef; $s->UnmapWindow; } else { $t->BackTrace('Cannot find' . $s->PathName); } $t->QueueLayout(_SlaveChange); } sub clear { my $self = shift; my $rows = $self->cget(-rows); my $cols = $self->cget(-columns); foreach my $r (1 .. $rows) { foreach my $c (1 .. $cols) { my $old = $self->get( $r, $c ); next unless $old; $self->LostSlave($old); $old->destroy; } } $self->_init; $self->QueueLayout(_SlaveSize); } sub _init { my $self = shift; $self->{'Width'} = []; $self->{'Height'} = []; $self->{'Row'} = []; $self->{'Slave'} = {}; $self->{'Top'} = 0; $self->{'Left'} = 0; $self->{'Bottom'} = 0; $self->{'Right'} = 0; $self->{LayoutPending} = 0; } sub put { my ($t,$row,$col,$w) = @_; $w = $t->Label(-text => $w) unless (ref $w); $t->ManageGeometry($w); unless (defined $t->{Row}[$row]) { $t->{Row}[$row] = []; $t->{Height}[$row] = 0; } unless (defined $t->{Width}[$col]) { $t->{Width}[$col] = 0; } my $old = $t->{Row}[$row][$col]; if (defined $old) { $old->UnmanageGeometry; $t->LostSlave($old); } $t->{Row}[$row][$col] = $w; $t->{Slave}{$w->PathName} = [$row,$col]; $t->SlaveGeometryRequest($w); $t->QueueLayout(_SlaveChange); return $old; } # # configure methods # sub scrollbars { my ($t,$v) = @_; if (@_ > 1) { $t->_configure(-scrollbars => $v); $t->QueueLayout(_ScrollBars); } return $t->_cget('-scrollbars'); } sub rows { my ($t,$r) = @_; if (@_ > 1) { $t->_configure(-rows => $r); if ($t->{Row} && @{$t->{Row}} > $r) { for my $y ($r .. $#{$t->{Row}}) { for my $s (@{$t->{Row}[$y]}) { $s->destroy if $s; } } splice @{ $t->{Row} }, $r; } $t->QueueLayout(_RowColCount); } return $t->_cget('-rows'); } sub fixedrows { my ($t,$r) = @_; if (@_ > 1) { $t->_configure(-fixedrows => $r); $t->QueueLayout(_RowColCount); } return $t->_cget('-fixedrows'); } sub columns { my ($t,$r) = @_; if (@_ > 1) { $t->_configure(-columns => $r); if ($t->{Row}) { for my $row (@{$t->{Row}}) { for my $s (@$row[$r .. $#$row]) { $s->destroy if $s; } { # FIXME? - Steve was getting warnings : # splice() offset past end of array local $^W = 0; splice @$row, $r; } } } $t->QueueLayout(_RowColCount); } return $t->_cget('-columns'); } sub fixedcolumns { my ($t,$r) = @_; if (@_ > 1) { $t->_configure(-fixedcolumns => $r); $t->QueueLayout(_RowColCount); } return $t->_cget('-fixedcolumns'); } 1; __END__ sub Create { my $t = shift; my $r = shift; my $c = shift; my $kind = shift; $t->put($r,$c,$t->$kind(@_)); } sub totalColumns { scalar @{shift->{'Width'}}; } sub totalRows { scalar @{shift->{'Height'}}; } sub Posn { my ($t,$s) = @_; my $info = $t->{Slave}{$s->PathName}; return (wantarray) ? @$info : $info; } sub see { my $t = shift; my ($row,$col) = (@_ == 2) ? @_ : @{$t->{Slave}{$_[0]->PathName}}; my $see = 1; if (($row -= $t->cget('-fixedrows')) >= 0) { if ($row < $t->{Top}) { $t->{Top} = $row; $t->QueueLayout(_ViewChange); $see = 0; } elsif ($row >= $t->{Bottom}) { $t->{Top} += ($row - $t->{Bottom}+1); $t->QueueLayout(_ViewChange); $see = 0; } } if (($col -= $t->cget('-fixedcolumns')) >= 0) { if ($col < $t->{Left}) { $t->{Left} = $col; $t->QueueLayout(_ViewChange); $see = 0; } elsif ($col >= $t->{Right}) { $t->{Left} += ($col - $t->{Right}+1); $t->QueueLayout(_ViewChange); $see = 0; } } return $see; }
Close