Re: Gtk2 1.152 (unstable) available
- From: Torsten Schoenfeld <kaffeetisch gmx de>
- To: gtk-perl-list gnome org
- Subject: Re: Gtk2 1.152 (unstable) available
- Date: Mon, 25 Jun 2007 22:19:47 +0200
On Sun, 2007-06-24 at 14:26 +0200, Torsten Schoenfeld wrote:
* Add support for GtkBuilder. [Torsten]
I'd like to hear some feedback on Gtk2::Builder from people who use
Gtk2::GladeXML. The new API is roughly:
$builder = Gtk2::Builder->new
followed by either
$builder->add_from_file ($file)
or
$builder->add_from_string ($buffer).
As for connecting signals, just as in Gtk2::GladeXML, you have three
options:
$builder->connect_signals ($user_data)
When invoked like this, Gtk2::Builder will connect signals to
functions in the main package whose names are specified in the
UI description.
$builder->connect_signals ($user_data, $package)
When invoked like this, Gtk2::Builder will connect signals to
functions in the package $package.
$builder->connect_signals ($user_data, %handlers)
When invoked like this, %handlers is used as a mapping from
handler names to code references.
Does this make sense? Is this how you'd expect the API to work? Is the
heavy overloading of connect_signals() too confusing? Do you have any
other suggestions?
--
Bye,
-Torsten
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]