diff options
author | Robin Gareus <robin@gareus.org> | 2017-07-17 18:34:35 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2017-07-17 21:06:04 +0200 |
commit | 601c317d70a03190257577bd867cefc2c70d3275 (patch) | |
tree | 077071290f084431a912414c4e87b6127c586677 /gtk2_ardour/time_axis_view_item.cc | |
parent | 1f5ebc54853446a786925941bd014666e75221d2 (diff) |
Clean up library inheritance (colors.h, utils.h)
make libwidget independent of libcanvas.
Confine basics to pbd and gtkmm2ext.
Diffstat (limited to 'gtk2_ardour/time_axis_view_item.cc')
-rw-r--r-- | gtk2_ardour/time_axis_view_item.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gtk2_ardour/time_axis_view_item.cc b/gtk2_ardour/time_axis_view_item.cc index 0587db9e2c..3f1adb9a1c 100644 --- a/gtk2_ardour/time_axis_view_item.cc +++ b/gtk2_ardour/time_axis_view_item.cc @@ -32,7 +32,7 @@ #include "canvas/rectangle.h" #include "canvas/debug.h" #include "canvas/text.h" -#include "canvas/colors.h" +#include "gtkmm2ext/colors.h" #include "ardour/profile.h" @@ -666,10 +666,10 @@ TimeAxisViewItem::set_name_text_color () f = get_fill_color (); } - name_text->set_color (ArdourCanvas::contrasting_text_color (f)); + name_text->set_color (contrasting_text_color (f)); } -ArdourCanvas::Color +Gtkmm2ext::Color TimeAxisViewItem::get_fill_color () const { const std::string mod_name = (_dragging ? "dragging region" : fill_color_name); @@ -714,20 +714,20 @@ TimeAxisViewItem::set_frame_gradient () ArdourCanvas::Fill::StopList stops; double r, g, b, a; double h, s, v; - ArdourCanvas::Color f (get_fill_color()); + Color f (get_fill_color()); /* need to get alpha value */ - ArdourCanvas::color_to_rgba (f, r, g, b, a); + color_to_rgba (f, r, g, b, a); stops.push_back (std::make_pair (0.0, f)); /* now a darker version */ - ArdourCanvas::color_to_hsv (f, h, s, v); + color_to_hsv (f, h, s, v); v = min (1.0, v * (1.0 - UIConfiguration::instance().get_timeline_item_gradient_depth())); - ArdourCanvas::Color darker = ArdourCanvas::hsva_to_color (h, s, v, a); + Color darker = hsva_to_color (h, s, v, a); stops.push_back (std::make_pair (1.0, darker)); frame->set_gradient (stops, true); |