Transparently instantiating derived widgets with Gtk::Builder
I'm currently in the process of updating a 15 year old tutorial¹ to the
current GTK+ 3.x release. Part of that is updating the use of libglade
to use Gtk::Builder. I have read the documentation about using derived
widgets² and the Gtk::Builder documentation³. However, I'm not entirely
satisfied with the result.
I would like to be able to instantiate my derived widget directly with
the Gtk::Builder stuff managed internally in the constructor so that the
end user does not need to know about it. Is this technically possible?
Can I use e.g. move-assignment with wrap() or get_widget_derived? It
looks possible, but I'm unsure how safe it would be. Has anyone done
this, or have any examples?