fix touch-recording of automation in a loop
[ardour.git] / gtk2_ardour / ardour_knob.cc
index 5543950ac17ee349b857a6082cacc7323a6f3c30..1cad9f4f552777741a6d6597b3d0f3e42e464174 100644 (file)
@@ -38,6 +38,7 @@
 #include "ardour_ui.h"
 #include "global_signals.h"
 
+#include "canvas/colors.h"
 #include "canvas/utils.h"
 
 #include "i18n.h"
@@ -88,7 +89,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
        cairo_translate (cr, xc, yc);  //after this, everything is based on the center of the knob
 
        //get the knob color from the theme
-       ArdourCanvas::Color knob_color = ARDOUR_UI::config()->color_by_name (string_compose ("%1", get_name()));
+       ArdourCanvas::Color knob_color = ARDOUR_UI::config()->color (string_compose ("%1", get_name()));
 
        float center_radius = 0.48*scale;
        float border_width = 0.8;
@@ -118,10 +119,10 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
 
                //look up the arc colors from the config
                double red_start, green_start, blue_start, unused;
-               ArdourCanvas::Color arc_start_color = ARDOUR_UI::config()->color_by_name ( string_compose ("%1: arc start", get_name()));
+               ArdourCanvas::Color arc_start_color = ARDOUR_UI::config()->color ( string_compose ("%1: arc start", get_name()));
                ArdourCanvas::color_to_rgba( arc_start_color, red_start, green_start, blue_start, unused );
                double red_end, green_end, blue_end;
-               ArdourCanvas::Color arc_end_color = ARDOUR_UI::config()->color_by_name ( string_compose ("%1: arc end", get_name()) );
+               ArdourCanvas::Color arc_end_color = ARDOUR_UI::config()->color ( string_compose ("%1: arc end", get_name()) );
                ArdourCanvas::color_to_rgba( arc_end_color, red_end, green_end, blue_end, unused );
 
                //vary the arc color over the travel of the knob
@@ -238,7 +239,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
        cairo_stroke (cr);
 
        //highlight if grabbed or if mouse is hovering over me
-       if ( _grabbed || (_hovering && ARDOUR::Config->get_widget_prelight() ) ) {
+       if ( _grabbed || (_hovering && ARDOUR_UI::config()->get_widget_prelight() ) ) {
                cairo_set_source_rgba (cr, 1,1,1, 0.12 );
                cairo_arc (cr, 0, 0, center_radius, 0, 2.0*G_PI);
                cairo_fill (cr);