Tk::Gpack 0.8
Sponsored Links
Tk::Gpack 0.8 Ranking & Summary
File size:
0.006 MB
Platform:
Any Platform
License:
Perl Artistic License
Price:
Downloads:
797
Date added:
2007-08-21
Publisher:
IT Operators
Tk::Gpack 0.8 description
Tk::Gpack module contains abbreviated geometry arguments for pack, grid and place geometry managers.
This module exports four functions for each of the different geometry mananers into the Tk namespace. These functions provide a variety of styles for controlling the indevidual geometry of one, or bulk groups of widgets. Each geometry manager has a series of single letter abbreviations allowing a significant reduction in code, while remaining fairly intuitive.
SYNOPSIS
use Tk::Gpack ;
gpack, ggrid, and gplace are group packers, they recieve an even numbered list of alternating widgets and abbreviations.
gpack($one, slan $two, sran $three, slanx1fb) ; # group pack
ggrid($one, r25c10, $two, c9r15, $three, c1r1se ) ; # group grid
gplace($one, w40h40x120y120anw, $two, x40y40ase, $three, aww20h20x25y140) ; # group placer
tpack, tgrid, and tplace are target packers, and use exactly the same format except they take a preceding target widget, (typically a frame) which will be automatically be used in conjunction with the -in => argument.
tpack($FRAME1, $one, slan $two, sran $three, slanx1fb) ; # target pack
tgrid($TOPLEVEL1, $one, r25c10, $two, c9r15, $three, c1r1se ) ; # target grid
tplace($MW, $one, w40h40x120y120anw, $two, x40y40ase, $three, aww20h20x25y140) ; # target placer
xpack xgrid and xplace are expand packers, and used inline as a direct replacement to pack grid and place. The first string passed is the abbreviation string, while anything remaining will be parsed as the standard verbose options.
$one->xpack(slan, -in => $FRAME1) ; # expand pack
$two->xgrid(r4c4sw, -in => $TOPLEVEL2) ; # expand grid
$three->xplace(x20y20aw, -in => $MW) ; # expand place
spack sgrid and splace are self packers, they assume that an abbreviation is embedded in the widget as an option called -geometry. You must be using derived widgets for this to work, and have defined a configspec -geometry. The self packers perform the same as xpack in that they permit additional verbose option pairs to be passed which will be appended to the expansion of the embedded abbreviation. If you are using a default widget geometry as shown below, you can still override it by simply using xpack in place of spack. (spack wont take the abbreviation as an argument) This is particularly handly for templated code. To use spack splace and sgrid do the following:
package DerivedButton ;
...
sub Populate {
$self->ConfigSpecs(-geometry => [PASSIVE, data, Data, slan]) ; # <------ Abbreviation
}
#!/usr/bin/perl -w
use Tk ;
...
my $DButton = $mw->DerivedButton()->spack(-in => $foo) ;
Obviously this last example is not complete. Once youve built a derived widget it should make sense though.
DETAILS
The abbreviations are fairly intuitive. All supported options are represented by a single character. For the pack geometry manager all passed values are also single characters. For grid and place passed values may be multiple characters. Numeric arguments for grid and place are variable length integers for example. There are a few redundant characters, but they work as expected.
NOT ALL OPTIONS TRANSLATE, in this version. (And probably for quite a few versions to come) But the most used ones do. Please review the following translation lists to see How things are supported at this time.
SUPPORTED TRANSLATIONS
# OPTIONS pack()
###################
x = -expand
s = -side
a = -anchor
f = -fill
X = -padx
Y = -pady
# VALUES pack()
####################
c = center
l = left
r = right
t = top
n = n
s = s
e = e
w = w
y = y
x = x
b = both
b = bottom
# OPTIONS grid()
####################
r = -row
c = -column
s = -sticky
# VALUES grid()
####################
n = n
s = s
e = e
w = w
# OPTIONS place()
####################
w = -width
h = -height
x = -x
y = -y
a = -anchor
# VALUES place()
####################
n = n
ne = ne
nw = nw
s = s
se = se
sw = sw
e = e
This module exports four functions for each of the different geometry mananers into the Tk namespace. These functions provide a variety of styles for controlling the indevidual geometry of one, or bulk groups of widgets. Each geometry manager has a series of single letter abbreviations allowing a significant reduction in code, while remaining fairly intuitive.
SYNOPSIS
use Tk::Gpack ;
gpack, ggrid, and gplace are group packers, they recieve an even numbered list of alternating widgets and abbreviations.
gpack($one, slan $two, sran $three, slanx1fb) ; # group pack
ggrid($one, r25c10, $two, c9r15, $three, c1r1se ) ; # group grid
gplace($one, w40h40x120y120anw, $two, x40y40ase, $three, aww20h20x25y140) ; # group placer
tpack, tgrid, and tplace are target packers, and use exactly the same format except they take a preceding target widget, (typically a frame) which will be automatically be used in conjunction with the -in => argument.
tpack($FRAME1, $one, slan $two, sran $three, slanx1fb) ; # target pack
tgrid($TOPLEVEL1, $one, r25c10, $two, c9r15, $three, c1r1se ) ; # target grid
tplace($MW, $one, w40h40x120y120anw, $two, x40y40ase, $three, aww20h20x25y140) ; # target placer
xpack xgrid and xplace are expand packers, and used inline as a direct replacement to pack grid and place. The first string passed is the abbreviation string, while anything remaining will be parsed as the standard verbose options.
$one->xpack(slan, -in => $FRAME1) ; # expand pack
$two->xgrid(r4c4sw, -in => $TOPLEVEL2) ; # expand grid
$three->xplace(x20y20aw, -in => $MW) ; # expand place
spack sgrid and splace are self packers, they assume that an abbreviation is embedded in the widget as an option called -geometry. You must be using derived widgets for this to work, and have defined a configspec -geometry. The self packers perform the same as xpack in that they permit additional verbose option pairs to be passed which will be appended to the expansion of the embedded abbreviation. If you are using a default widget geometry as shown below, you can still override it by simply using xpack in place of spack. (spack wont take the abbreviation as an argument) This is particularly handly for templated code. To use spack splace and sgrid do the following:
package DerivedButton ;
...
sub Populate {
$self->ConfigSpecs(-geometry => [PASSIVE, data, Data, slan]) ; # <------ Abbreviation
}
#!/usr/bin/perl -w
use Tk ;
...
my $DButton = $mw->DerivedButton()->spack(-in => $foo) ;
Obviously this last example is not complete. Once youve built a derived widget it should make sense though.
DETAILS
The abbreviations are fairly intuitive. All supported options are represented by a single character. For the pack geometry manager all passed values are also single characters. For grid and place passed values may be multiple characters. Numeric arguments for grid and place are variable length integers for example. There are a few redundant characters, but they work as expected.
NOT ALL OPTIONS TRANSLATE, in this version. (And probably for quite a few versions to come) But the most used ones do. Please review the following translation lists to see How things are supported at this time.
SUPPORTED TRANSLATIONS
# OPTIONS pack()
###################
x = -expand
s = -side
a = -anchor
f = -fill
X = -padx
Y = -pady
# VALUES pack()
####################
c = center
l = left
r = right
t = top
n = n
s = s
e = e
w = w
y = y
x = x
b = both
b = bottom
# OPTIONS grid()
####################
r = -row
c = -column
s = -sticky
# VALUES grid()
####################
n = n
s = s
e = e
w = w
# OPTIONS place()
####################
w = -width
h = -height
x = -x
y = -y
a = -anchor
# VALUES place()
####################
n = n
ne = ne
nw = nw
s = s
se = se
sw = sw
e = e
Tk::Gpack 0.8 Screenshot
Tk::Gpack 0.8 Keywords
Gpack 0.8
OPTIONS
VALUES
geometry
grid
pack
place
s
one
Tk::Gpack
TkGpack
Tk::Gpack 0.8
Libraries
Programming
Bookmark Tk::Gpack 0.8
Tk::Gpack 0.8 Copyright
WareSeeker periodically updates pricing and software information of Tk::Gpack 0.8 full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Tk::Gpack 0.8 Edition. Download links are directly from our publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed
Featured Software
Want to place your software product here?
Please contact us for consideration.
Contact WareSeeker.com
Related Information
Related Software
TTraffic project is a Tcl/Tk version of the game Rush Hour. Free Download
TkMAME project is a Tcl/Tk Front End for XMAME. Free Download
Tk::Getopt is a user configuration window for Tk with interface to Getopt::Long. Free Download
Tk::Help is simple widget for creating a help system for Perl/Tk applications. Free Download
Tk::Date is a date/time widget for perl/Tk. Free Download
Ptk Phone is a small program written in Perl/Tk to be used as an address book. Free Download
scrot is a command line screen capture utility. Free Download
Tk::SplitFrame is a geometry manager for scaling two subwidgets. Free Download
Latest Software
Popular Software
Favourite Software