With the debian packaged perl-gtk 1.140 and glib 1.161, and gtk 2.12.0 and glib 2.14.1, I had a little go at subclassing a GtkLabel, and in a "size_request" method calling up to the corresponding superclass code using signal_chain_from_overridden(). See Foo.pm and main.pl below, "perl main.pl". Alas signal_chain_from_overridden doesn't seem to touch the requisition object, it just stays as size "0x0", where I hoped for something like "72x17" (which is the case with no signal_request method in the subclass). Have I misunderstood something fundamental? I was sort of copying what the histogramplot.pl example does, and wanted something like in C GTK_WIDGET_CLASS (my_foo_parent_class)->size_request (widget, requisition); I suspect actually for what I'm trying to do (tinkering with a clock as a subclass of GtkLabel) I ought to calculate a desired size on my own, in advance, instead of asking the superclass and manipulating its result. But playing around made me wonder what I was doing wrong seemingly not to reach the superclass code at all.
Attachment:
Foo.pm
Description: Text Data
Attachment:
main.pl
Description: Text Data