Gnome::Gtk4::CellRendererPixbuf
Description
Renders a pixbuf in a cell
A Gnome::Gtk4::CellRendererPixbuf can be used to render an image in a cell. It allows to render either a given Gnome::GdkPixbuf::Pixbuf (set via the Gnome::Gtk4::CellRendererPixbuf:pixbuf` property) or a named icon (set via the Gnome::Gtk4::CellRendererPixbuf:icon-name` property).
To support the tree view, Gnome::Gtk4::CellRendererPixbuf also supports rendering two alternative pixbufs, when the Gnome::Gtk4::CellRenderer:is-expander` property is True
. If the Gnome::Gtk4::CellRenderer:is-expanded property` is True
and the Gnome::Gtk4::CellRendererPixbuf:pixbuf-expander-open` property is set to a pixbuf, it renders that pixbuf, if the Gnome::Gtk4::CellRenderer:is-expanded` property is False
and the Gnome::Gtk4::CellRendererPixbuf:pixbuf-expander-closed` property is set to a pixbuf, it renders that one.
Class initialization
Note: The native version of this class is deprecated in gtk4-lib() since version 4.10
new
:native-object
Create an object using a native object from elsewhere. See also Gnome::N::TopLevelSupportClass.
multi method new ( N-Object :$native-object! )
new-cellrendererpixbuf
Note: The native version of this routine is deprecated in gtk4-lib() since version 4.10
Creates a new Gnome::Gtk4::CellRendererPixbuf. Adjust rendering parameters using object properties. Object properties can be set globally (with g_object_set()). Also, with Gnome::Gtk4::TreeViewColumn, you can bind a property to a value in a Gnome::Gtk4::R-TreeModel. For example, you can bind the “pixbuf” property on the cell renderer to a pixbuf value in the model, thus rendering a different image in each row of the Gnome::Gtk4::TreeView.
method new-cellrendererpixbuf ( --> Gnome::Gtk4::CellRendererPixbuf \)