Picture.for_pixbuf


Description:

[ CCode ( has_construct_function = false , type = "GtkWidget*" ) ]
[ Version ( deprecated = true , deprecated_since = "4.12" ) ]
public Picture.for_pixbuf (Pixbuf? pixbuf)

Warning: Picture.for_pixbuf is deprecated since 4.12.

Creates a new `GtkPicture` displaying pixbuf.

Note:

Use [ctor@Gtk.Picture.new_for_paintable] and [ctor@Gdk.Texture.new_for_pixbuf] instead

This is a utility function that calls [ctor@Gtk.Picture.new_for_paintable], See that function for details.

The pixbuf must not be modified after passing it to this function.

Parameters:

pixbuf

a `GdkPixbuf`

Returns:

a new `GtkPicture`