Gtk2::TextTagTable(3)
π Gtk2::TextTagTable β bestie edition π
okay so you found Gtk2::TextTagTable, the Perl wrapper for GtkTextTagTable, in the User Contributed Perl Documentation section. it's giving "the little backstage closet where all your text tags live" β¨ and honestly? iconic.
π HIERARCHY
Glib::Object
+----Gtk2::TextTagTable
so it's a Glib::Object at heart, and Gtk2::TextTagTable is the glow-up that inherits from it. family tree, slay. π
π INTERFACES
Gtk2::Buildable
yep, it's also Gtk2::Buildable, which means it can be built up from builder files. main character energy fr fr. π
β¨ METHODS
π texttagtable = Gtk2::TextTagTable->new
makes you a brand new Gtk2::TextTagTable. fresh table, no tags, no drama, blank canvas, we love to see it. π¦
πΈ $table->add ($tag)
drops a tag into the table. the deets:
$tagis aGtk2::TextTagπ·οΈ
π«Ά $table->foreach ($callback, $callback_data=undef)
runs your $callback over the tags. and yes, you can pass extra stuff along for the ride:
$callbackβ a scalar (yes, your callback comes in as a scalar, that's just how it is bestie)$callback_dataβ a scalar, and it defaults toundefif you don't hand it anything π
π texttag = $table->lookup ($name)
finds you a tag by name. you give it a string, it gives you back the texttag:
$nameis a string
π
$table->remove ($tag)
yeets a tag out of the table. bye boo π
$tagis aGtk2::TextTag
β integer = $table->get_size
gives you an integer β the number of tags chillin' in the table. no cap. π
π₯ SIGNALS
these are the little notifications the table sends out into the world:
tag-added (Gtk2::TextTagTable, Gtk2::TextTag)β a tag just showed up πtag-changed (Gtk2::TextTagTable, Gtk2::TextTag, boolean)β a tag changed, and there's abooleanriding along with the news π£tag-removed (Gtk2::TextTagTable, Gtk2::TextTag)β a tag left the chat π
π SEE ALSO
Gtk2Glib::Object
go read those, iykyk π§
π COPYRIGHT
Copyright (C) 2003-2011 by the gtk2-perl team.
This software is licensed under the LGPL. See Gtk2 for a full notice.
and that's the whole page, bestie! π this was Gtk2::TextTagTable(3) from the User Contributed Perl Documentation, generated by perl v5.42.0 on 2025-07-25 β mwah, take care of her π«Άβ¨π
π¦ where this page comes from
- fedora 43: perl-Gtk2 1.24993-23.fc43 Β· LicenseRef-Callaway-LGPLv2+
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms