Add browse button to recent session dialogue. Fixes #3357.
[ardour.git] / gtk2_ardour / cairo_widget.h
index ee0bed114b2b657ee47d2b0acc2813f40a95c27f..8665f66198981e03ed39a2fd932ede6025979beb 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2009 Paul Davis 
+    Copyright (C) 2009 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
 
 #include <gtkmm/eventbox.h>
 
+/** A parent class for widgets that are made up of a pixmap rendered using Cairo.
+ *  The pixmap is painted to screen on GTK expose events, but the rendering
+ *  is only done after set_dirty() has been called.
+ */
+
 class CairoWidget : public Gtk::EventBox
 {
 public:
@@ -31,16 +36,17 @@ public:
        void set_dirty ();
 
 protected:
+       /** Render the widget to the given Cairo context */
        virtual void render (cairo_t *) = 0;
        virtual bool on_expose_event (GdkEventExpose *);
        void on_size_allocate (Gtk::Allocation &);
 
        int _width; ///< pixmap width
        int _height; ///< pixmap height
-       
+
 private:
-       bool _dirty;
-       GdkPixmap* _pixmap;
+       bool _dirty; ///< true if the pixmap requires re-rendering
+       GdkPixmap* _pixmap; ///< our pixmap
 };
 
 #endif