diff --git a/gtk2_ardour/editor_canvas.cc b/gtk2_ardour/editor_canvas.cc index 8a5c6999cf..359b7d5526 100644 --- a/gtk2_ardour/editor_canvas.cc +++ b/gtk2_ardour/editor_canvas.cc @@ -170,6 +170,9 @@ Editor::initialize_canvas () tempo_bar = new ArdourCanvas::Rectangle (tempo_group, ArdourCanvas::Rect (0.0, 0.0, ArdourCanvas::COORD_MAX, timebar_height)); CANVAS_DEBUG_NAME (tempo_bar, "Tempo Bar"); + tempo_bar->set_fill(true); + tempo_bar->set_outline(false); + tempo_bar->set_outline_what(ArdourCanvas::Rectangle::BOTTOM); range_marker_bar = new ArdourCanvas::Rectangle (range_marker_group, ArdourCanvas::Rect (0.0, timebar_top, ArdourCanvas::COORD_MAX, timebar_btm)); CANVAS_DEBUG_NAME (range_marker_bar, "Range Marker Bar"); @@ -1026,14 +1029,25 @@ Editor::color_handler() _playhead_cursor->set_color (UIConfiguration::instance().color ("play head")); - //these have no color (transparent) until moused-over - meter_bar->set_fill_color (0); - tempo_bar->set_fill_color (0); - cd_marker_bar->set_fill_color (0); - cue_marker_bar->set_fill_color (0); - range_marker_bar->set_fill_color (0); - marker_bar->set_fill_color (0); - transport_marker_bar->set_fill_color (0); + meter_bar->set_fill_color (UIConfiguration::instance().color_mod ("meter bar", "marker bar")); + meter_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); + + tempo_bar->set_fill_color (UIConfiguration::instance().color_mod ("tempo bar", "marker bar")); + + marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("marker bar", "marker bar")); + marker_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); + + cd_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("cd marker bar", "marker bar")); + cd_marker_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); + + cue_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("cd marker bar", "marker bar")); + cue_marker_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); + + range_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); + range_marker_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); + + transport_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("transport marker bar", "marker bar")); + transport_marker_bar->set_outline_color (UIConfiguration::instance().color ("marker bar separator")); cd_marker_bar_drag_rect->set_fill_color (UIConfiguration::instance().color ("range drag bar rect")); cd_marker_bar_drag_rect->set_outline_color (UIConfiguration::instance().color ("range drag bar rect")); diff --git a/gtk2_ardour/editor_canvas_events.cc b/gtk2_ardour/editor_canvas_events.cc index 5728e7be4c..b4727d49a7 100644 --- a/gtk2_ardour/editor_canvas_events.cc +++ b/gtk2_ardour/editor_canvas_events.cc @@ -984,12 +984,12 @@ Editor::canvas_marker_bar_event (GdkEvent *event, ArdourCanvas::Item* item) switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - marker_bar->set_fill_color (0xFFFFFF20); + marker_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.5).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - marker_bar->set_fill_color (0); + marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); } break; default: @@ -1005,12 +1005,12 @@ Editor::canvas_range_marker_bar_event (GdkEvent *event, ArdourCanvas::Item* item switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - range_marker_bar->set_fill_color (0xFFFFFF20); + range_marker_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.5).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - range_marker_bar->set_fill_color (0); + range_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); } break; default: @@ -1026,12 +1026,12 @@ Editor::canvas_transport_marker_bar_event (GdkEvent *event, ArdourCanvas::Item* switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - transport_marker_bar->set_fill_color (0xFFFFFF20); + transport_marker_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.5).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - transport_marker_bar->set_fill_color (0); + transport_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); } break; default: @@ -1047,12 +1047,12 @@ Editor::canvas_cd_marker_bar_event (GdkEvent *event, ArdourCanvas::Item* item) switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - cd_marker_bar->set_fill_color (0xFFFFFF20); //TODO: theme these + cd_marker_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.25).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - cd_marker_bar->set_fill_color (0); + cd_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); } break; default: @@ -1068,12 +1068,12 @@ Editor::canvas_cue_marker_bar_event (GdkEvent *event, ArdourCanvas::Item* item) switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - cue_marker_bar->set_fill_color (0xFFFFFF20); + cue_marker_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.5).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - cue_marker_bar->set_fill_color (0); + cue_marker_bar->set_fill_color (UIConfiguration::instance().color_mod ("range marker bar", "marker bar")); } break; default: @@ -1177,12 +1177,12 @@ Editor::canvas_tempo_bar_event (GdkEvent *event, ArdourCanvas::Item* item) switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - tempo_bar->set_fill_color (0xFFFFFF20); //TODO: theme these + tempo_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.25).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - tempo_bar->set_fill_color (0); + tempo_bar->set_fill_color (UIConfiguration::instance().color_mod ("tempo bar", "marker bar")); } break; default: @@ -1198,12 +1198,12 @@ Editor::canvas_meter_bar_event (GdkEvent *event, ArdourCanvas::Item* item) switch (event->type) { case GDK_ENTER_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - meter_bar->set_fill_color (0xFFFFFF20); //TODO: theme these + meter_bar->set_fill_color (Gtkmm2ext::HSV(UIConfiguration::instance().color ("marker bar")).lighter(0.25).color()); } break; case GDK_LEAVE_NOTIFY: if (event->crossing.detail != GDK_NOTIFY_INFERIOR) { - meter_bar->set_fill_color (0); + meter_bar->set_fill_color (UIConfiguration::instance().color_mod ("meter bar", "marker bar")); } break; default: