Gtk.CellRendererPixbuf¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
Virtual Methods¶
- Inherited:
Properties¶
- Inherited:
Name |
Type |
Flags |
Short Description |
---|---|---|---|
d/r/w |
Whether the rendered pixbuf should be colorized according to the state |
||
r/w |
The |
||
r/w |
The name of the icon from the icon theme |
||
r/w |
The pixbuf to render |
||
r/w |
Pixbuf for closed expander |
||
r/w |
Pixbuf for open expander |
||
r/w |
Render detail to pass to the theme engine |
||
d/r/w |
The stock ID of the stock icon to render |
||
r/w |
The |
||
r/w |
The surface to render |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent |
r |
Class Details¶
- class Gtk.CellRendererPixbuf(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
A
Gtk.CellRendererPixbuf
can be used to render an image in a cell. It allows to render either a givenGdkPixbuf.Pixbuf
(set via theGtk.CellRendererPixbuf
:pixbuf
property) or a named icon (set via theGtk.CellRendererPixbuf
:icon-name
property).To support the tree view,
Gtk.CellRendererPixbuf
also supports rendering two alternative pixbufs, when theGtk.CellRenderer
:is-expander
property isTrue
. If theGtk.CellRenderer
:is-expanded
property isTrue
and theGtk.CellRendererPixbuf
:pixbuf-expander-open
property is set to a pixbuf, it renders that pixbuf, if theGtk.CellRenderer
:is-expanded
property isFalse
and theGtk.CellRendererPixbuf
:pixbuf-expander-closed
property is set to a pixbuf, it renders that one.- classmethod new()[source]¶
- Returns:
the new cell renderer
- Return type:
Creates a new
Gtk.CellRendererPixbuf
. Adjust rendering parameters using object properties. Object properties can be set globally (with g_object_set()). Also, withGtk.TreeViewColumn
, you can bind a property to a value in aGtk.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 theGtk.TreeView
.
Property Details¶
- Gtk.CellRendererPixbuf.props.follow_state¶
- Name:
follow-state
- Type:
- Default Value:
- Flags:
Specifies whether the rendered pixbuf should be colorized according to the
Gtk.CellRendererState
.New in version 2.8.
Deprecated since version 3.16: Cell renderers always follow state.
- Gtk.CellRendererPixbuf.props.gicon¶
-
The
Gio.Icon
representing the icon to display. If the icon theme is changed, the image will be updated automatically.New in version 2.14.
- Gtk.CellRendererPixbuf.props.icon_name¶
-
The name of the themed icon to display. This property only has an effect if not overridden by “stock_id” or “pixbuf” properties.
New in version 2.8.
- Gtk.CellRendererPixbuf.props.pixbuf¶
- Name:
pixbuf
- Type:
- Default Value:
- Flags:
The pixbuf to render
- Gtk.CellRendererPixbuf.props.pixbuf_expander_closed¶
- Name:
pixbuf-expander-closed
- Type:
- Default Value:
- Flags:
Pixbuf for closed expander
- Gtk.CellRendererPixbuf.props.pixbuf_expander_open¶
- Name:
pixbuf-expander-open
- Type:
- Default Value:
- Flags:
Pixbuf for open expander
- Gtk.CellRendererPixbuf.props.stock_detail¶
-
Render detail to pass to the theme engine
- Gtk.CellRendererPixbuf.props.stock_id¶
- Name:
stock-id
- Type:
- Default Value:
- Flags:
The stock ID of the stock icon to render
New in version 2.2.
Deprecated since version 3.10: Use
Gtk.CellRendererPixbuf
:icon-name
instead.
- Gtk.CellRendererPixbuf.props.stock_size¶
-
The
Gtk.IconSize
value that specifies the size of the rendered icon.New in version 2.2.
- Gtk.CellRendererPixbuf.props.surface¶
- Name:
surface
- Type:
- Default Value:
- Flags:
The surface to render
New in version 3.10.