Gtk2::E...onstants(3)
π NAME π
Gtk2 Ex Constants β the lil extra-constants situation for working with Gnome2/Gtk2 in Perl. (The man page itself shows up as Gtk2::E...onstants(3) because the terminal is a hater and truncates, but bestie, it's the same vibe. π
)
β¨ SYNOPSIS β¨
Like, here's how you actually pull them in:
# import only the PACKing and PADing constants
use Gtk2::Constants qw( :pack :pad );
That's it. That's the whole vibe. π«Ά
πΈ DESCRIPTION πΈ
So this module is basically a big ol' bag of constant values for very specific lil corners of working with Gnome2/Gtk2 Perl. The main character reason these constants exist (besides giving you unified values so you're not out here guessing) is to help you write human-readable code that follows consistent naming conventions. It's giving clean code, it's giving you'll-actually-understand-this-in-six-months. No cap. π
π EXPORT TAGS π
These are the tags you can pull in:
:all :truth :pad :pack :align :justify :policy
π CONSTANTS BY TAG π
π¦ :truth
The booleans, the yes-and-no of it all:
TRUE = 1
FALSE = 0
π :pad
Spacing constants, for when your widgets need room to breathe:
PAD_EDGE = 12
PAD_WIDGET = 8
PAD_ZERO = 0
π :pack
Packing constants β note these are two-value pairs ( expand, fill ):
PACK_EXPAND = ( 1, 0 )
PACK_FILL = ( 0, 1 )
PACK_ZERO = ( 0, 0 )
PACK_GROW = ( 1, 1 )
β :align
Alignment floats, because centering things is, lowkey, a whole personality trait:
A_LEFT = 0.00
A_CENTRE = 0.50
A_RIGHT = 1.00
A_TOP = 0.00
A_MIDDLE = 0.50
A_BOTTOM = 1.00
π :justify
Justification strings β the horizontal ones and the vertical ones live together here, iykyk:
J_LEFT = 'left'
J_CENTRE = 'center'
J_RIGHT = 'right'
J_FILL = 'fill'
π§ :policy
Scrollbar policy strings, for when you can't decide how much scrolling you're emotionally available for:
P_ALWAYS = 'always'
P_AUTO = 'automatic'
P_NEVER = 'never'
π BUGS π
Please report any bugs to the mailing list. (Mailing list deets are right below, bestie, don't scroll away. π«Ά)
π CONTRIBUTE π
Okay so if you've got constants that are related to Gnome2/Gtk2 Perl, that are not already implemented in here, and you feel like other people might benefit from having them included? Please do not hesitate to send them to the mailing list. Sharing is caring, and honestly it's giving community. π
π¬ MAILING LIST π¬
http://opendoorsoftware.com/lists/gtk2-ex-list
gtk2-ex-list@opendoorsoftware.com
π AUTHORS π
The icons who made this:
Kevin C. Krinke, <kckrinke@opendoorsoftware.com>
James Greenhalgh, <jgreenhalgh@opendoorsoftware.com>
βοΈ COPYRIGHT AND LICENSE βοΈ
Gtk2::Ex::Constants - Useful constants for working with Gnome2/Gtk2 Perl.
Copyright (C) 2005 Open Door Software Inc. <ods@opendoorsoftware.com>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Fr fr, read the license, bestie β it's the LGPL v2.1-or-later and it's doing the legal heavy lifting so you don't have to. π«Ά
And that's the whole page!! This lil doc shipped as part of perl v5.42.0, dated 2025-07-25. Thanks for reading, you absolute scholar β go forth and write some consistent, human-readable Gtk2 Perl. Periodt. π
β¨
π¦ where this page comes from
- fedora 43: perl-Gtk2-Ex-Utils 0.09-49.fc43 Β· LicenseRef-Callaway-LGPLv2+
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms