-
- f = ARDOUR_UI::config()->get_canvasvar_SelectedFrameBase();
-
- if (fill_opacity != 0) {
- o = fill_opacity;
- } else {
- /* some condition of this item has set fill opacity to
- * zero, but it has been selected, so use a mid-way
- * alpha value to make it reasonably visible.
- */
- o = 130;
- }
-
- } else {
-
- if (_recregion) {
- f = ARDOUR_UI::config()->get_canvasvar_RecordingRect();
- } else {
- if ((!Config->get_show_name_highlight() || high_enough_for_name) && !ARDOUR_UI::config()->get_color_regions_using_track_color()) {
- f = ARDOUR_UI::config()->get_canvasvar_FrameBase();
- /* use the opacity as set for the FrameBase color */
- o = UINT_RGBA_A (f);
- } else {
- f = fill_color;
- o = fill_opacity;
- }
- }
-
- /* tweak opacity */
-
- if (!rect_visible) {
- /* if the frame/rect is marked as invisible, then the
- * fill should be transparent. simplest: set
- * alpha/opacity to zero.
- */
- o = 0;
- }
+ return UIConfiguration::instance().color_mod ("selected region base", mod_name);
+ } else if (_recregion) {
+ return UIConfiguration::instance().color ("recording rect");
+ } else if ((!UIConfiguration::instance().get_show_name_highlight() || high_enough_for_name) &&
+ !UIConfiguration::instance().get_color_regions_using_track_color()) {
+ return UIConfiguration::instance().color_mod (fill_color_name, mod_name);