Gtk2::Rc(3)
π Gtk2::Rc π
okay bestie, so this is Gtk2::Rc β the part of gtk2-perl that handles your GTK+ resource files (rc files, the little style sheets of the GTK+ world π). It lives in the User Contributed Perl Documentation section of your man pages, and it's giving "quietly holding the whole look together" energy. π
β¨ METHODS β¨
πΈ Gtk2::Rc->add_default_file ($filename)
adds a file to the default list, no biggie π
$filenameβ a localized file name (yes, that's the type, we don't make the rules)
π¦ list = Gtk2::Rc->get_default_files
hands you back the list of files that GTK+ is gonna read at the very end of Gtk2->init. it's the guest list, basically. β¨
π Gtk2::Rc->set_default_files (file1, ...)
...β a list of strings, the rc files to be parsed ποΈ$file1β a localized file name
this one sets the list of files that GTK+ will read at the end of Gtk2->init. you're rewriting the guest list. main character move. π
π§ string = Gtk2::Rc->get_im_module_file
returns a string, that's the whole vibe π
π string = Gtk2::Rc->get_im_module_path
also a string. we love a consistent queen. β¨
π string = Gtk2::Rc->get_module_dir
yep. string. π
π Gtk2::Rc->parse ($filename)
$filenameβ a localized file name
feed it a file, it parses it. simple as. π«Ά
β Gtk2::Rc->parse_string ($rc_string)
$rc_stringβ a string
same energy as parse, except you're handing over the actual string instead of a file. iconic flexibility. π
π₯ boolean = Gtk2::Rc->reparse_all
returns a boolean. it's a yes-or-no situation and it's giving yes. β
π boolean = Gtk2::Rc->reparse_all_for_settings ($settings, $force_load)
$settingsβ aGtk2::Settings$force_loadβ a boolean
returns a boolean too. the $force_load is literally the "no like actually do it" flag. π€
πΈ Gtk2::Rc->reset_styles ($settings)
$settingsβ aGtk2::Settings
Since: gtk+ 2.4 β so if you're on something ancient, this isn't for you bestie π
π style = Gtk2::Rc->get_style_by_paths ($settings, $widget_path, $class_path, $package)
the β¨deluxeβ¨ version, where you tell it exactly where to look:
$settingsβ aGtk2::Settings$widget_pathβ a string$class_pathβ a string$packageβ a string
π¦ style = Gtk2::Rc->get_style ($widget)
$widgetβ aGtk2::Widget
just hand over a widget and get its style back. no paths required, we're keeping it simple. π
π string = Gtk2::Rc->get_theme_dir
string. theme dir. that's it, that's the method. β¨
π SEE ALSO π
Gtk2β go read that one too, it's the whole universe this little page lives in π
π 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::Rc(3) from the User Contributed Perl Documentation, sitting pretty at perl v5.42.0, dated 2025-07-25 ππ¦ go forth and style responsibly, ily, bye!! ππ
π¦ 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