/*
- Copyright (C) 2012 Paul Davis
+ Copyright (C) 2012 Paul Davis
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
int x, y;
Gtk::Widget* window_parent;
Glib::RefPtr<Gdk::Window> win = Gtkmm2ext::window_to_draw_on (w, &window_parent);
-
+
if (win) {
-
+
Cairo::RefPtr<Cairo::Context> context = win->create_cairo_context();
w.translate_coordinates (*window_parent, 0, 0, x, y);
return HBox::on_expose_event (ev);
}
+void
+CairoHPacker::on_size_allocate (Gtk::Allocation& alloc)
+{
+ get_parent()->queue_draw();
+ HBox::on_size_allocate (alloc);
+}
+
CairoVPacker::CairoVPacker ()
{
}
CairoWidget::provide_background_for_cairo_widget (*this, get_bg());
}
+void
+CairoVPacker::on_size_allocate (Gtk::Allocation& alloc)
+{
+ get_parent()->queue_draw();
+ VBox::on_size_allocate (alloc);
+}
+
Gdk::Color
CairoVPacker::get_bg () const
{