1 #include <cairomm/cairomm.h>
2 #include <gdkmm/general.h>
6 #include "canvas/pixbuf.h"
9 using namespace ArdourCanvas;
11 Pixbuf::Pixbuf (Group* g)
18 Pixbuf::render (Rect const & /*area*/, Cairo::RefPtr<Cairo::Context> context) const
20 Gdk::Cairo::set_source_pixbuf (context, _pixbuf, 0, 0);
25 Pixbuf::compute_bounding_box () const
28 _bounding_box = boost::optional<Rect> (Rect (0, 0, _pixbuf->get_width(), _pixbuf->get_height()));
30 _bounding_box = boost::optional<Rect> ();
33 _bounding_box_dirty = false;
37 Pixbuf::set (Glib::RefPtr<Gdk::Pixbuf> pixbuf)
42 _bounding_box_dirty = true;
48 Pixbuf::get_state () const
51 return new XMLNode ("Pixbuf");
55 Pixbuf::set_state (XMLNode const * /*node*/)