diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2014-06-09 23:28:32 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2014-06-09 23:29:00 -0400 |
commit | ce08ec0de0b0b077d9b28533c23886607991d144 (patch) | |
tree | 031a01c89075fbf90733da202ce8b19f6f048a6c /gtk2_ardour/region_view.cc | |
parent | 438179d278559bcb41a8abdadfb5e6b2e1e89d2d (diff) |
substantial changes in color management, involving a reduction in the use of Gdk::Color and more consistent logic for region coloring.
Group tabs now also get the text drawn in an appropriately contrast-y color
Diffstat (limited to 'gtk2_ardour/region_view.cc')
-rw-r--r-- | gtk2_ardour/region_view.cc | 24 |
1 files changed, 4 insertions, 20 deletions
diff --git a/gtk2_ardour/region_view.cc b/gtk2_ardour/region_view.cc index c566d54f2d..378488ab51 100644 --- a/gtk2_ardour/region_view.cc +++ b/gtk2_ardour/region_view.cc @@ -66,7 +66,7 @@ RegionView::RegionView (ArdourCanvas::Group* parent, TimeAxisView& tv, boost::shared_ptr<ARDOUR::Region> r, double spu, - Gdk::Color const & basic_color, + uint32_t basic_color, bool automation) : TimeAxisViewItem (r->name(), *parent, tv, spu, basic_color, r->position(), r->length(), false, automation, (automation ? TimeAxisViewItem::ShowFrame : @@ -131,7 +131,7 @@ RegionView::RegionView (ArdourCanvas::Group* parent, TimeAxisView& tv, boost::shared_ptr<ARDOUR::Region> r, double spu, - Gdk::Color const & basic_color, + uint32_t basic_color, bool recording, TimeAxisViewItem::Visibility visibility) : TimeAxisViewItem (r->name(), *parent, tv, spu, basic_color, r->position(), r->length(), recording, false, visibility) @@ -152,7 +152,7 @@ RegionView::RegionView (ArdourCanvas::Group* parent, } void -RegionView::init (Gdk::Color const & basic_color, bool wfd) +RegionView::init (bool wfd) { editor = 0; valid = true; @@ -163,8 +163,6 @@ RegionView::init (Gdk::Color const & basic_color, bool wfd) sync_mark = 0; sync_line = 0; - compute_colors (basic_color); - if (name_highlight) { name_highlight->set_data ("regionview", this); name_highlight->Event.connect (sigc::bind (sigc::mem_fun (PublicEditor::instance(), &PublicEditor::canvas_region_view_name_highlight_event), name_highlight, this)); @@ -539,9 +537,7 @@ RegionView::set_frame_color () return; } - if (_region->opaque()) { - fill_opacity = 130; - } else { + if (!_region->opaque()) { fill_opacity = 60; } @@ -549,18 +545,6 @@ RegionView::set_frame_color () } void -RegionView::fake_set_opaque (bool yn) -{ - if (yn) { - fill_opacity = 130; - } else { - fill_opacity = 60; - } - - set_frame_color (); -} - -void RegionView::show_region_editor () { if (editor == 0) { |