20 #ifndef __gtkmm2ext_pixfader_h__
21 #define __gtkmm2ext_pixfader_h__
27 #include <gtkmm/adjustment.h>
37 PixFader (Gtk::Adjustment& adjustment,
int orientation,
int span,
int girth);
44 void set_default_value (
float);
45 void set_text (
const std::string&,
bool centered =
true,
bool expose =
true);
48 NoShowUnityLine = 0x1,
49 NoButtonForward = 0x2,
50 NoVerticalScroll = 0x4,
54 void set_tweaks (Tweaks);
57 void on_size_request (GtkRequisition*);
58 void on_size_allocate (Gtk::Allocation& alloc);
60 void render (cairo_t *, cairo_rectangle_t*);
61 bool on_button_press_event (GdkEventButton*);
62 bool on_button_release_event (GdkEventButton*);
63 bool on_motion_notify_event (GdkEventMotion*);
64 bool on_scroll_event (GdkEventScroll* ev);
65 bool on_enter_notify_event (GdkEventCrossing* ev);
66 bool on_leave_notify_event (GdkEventCrossing* ev);
68 void on_state_changed (Gtk::StateType);
69 void on_style_changed (
const Glib::RefPtr<Gtk::Style>&);
100 Gdk::Color get_parent_bg ();
102 void create_patterns();
103 void adjustment_changed ();
104 void set_adjustment_from_event (GdkEventButton *);
105 void update_unity_position ();
120 double afr,
double afg,
double afb,
121 double abr,
double abg,
double abb,
134 bool matches (
double afr,
double afg,
double afb,
135 double abr,
double abg,
double abb,
149 static cairo_pattern_t* find_pattern (
double afr,
double afg,
double afb,
150 double abr,
double abg,
double abb,
Gtk::Adjustment & _adjustment
sigc::signal< void > StartGesture
cairo_pattern_t * pattern
bool matches(double afr, double afg, double afb, double abr, double abg, double abb, int w, int h)
Glib::RefPtr< Pango::Layout > _layout
static std::list< FaderImage * > _patterns
sigc::connection _parent_style_change
FaderImage(cairo_pattern_t *p, double afr, double afg, double afb, double abr, double abg, double abb, int w, int h)
cairo_pattern_t * _pattern
sigc::signal< void > OnExpose
sigc::signal< void > StopGesture