Re: Images

On 12/19/00 Vandana wrote:
      Is there a way to add gif images to widgets? How is it done?

You load the image with either Gtk::Gdk::ImlibImage or
Gtk::Gdk::Pixbuf, create a Gtk::Gdk::Pixmap out of it
and put it in a Gtk::Pixmap widget.

$pixbuf = new_from_file Gtk::Gdk::Pixbuf($file);
($pixmap, $mask) = $pixbuf->render_pixmap_and_mask($alpha_threshold);


lupus debian org                                     debian/rules
lupus helixcode com                          Monkeys do it better

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]