Lower transparency of marker/etc bars so tempo lines show.
[ardour.git] / gtk2_ardour / automation_time_axis.cc
index bfc0ce4440b8c6a5217d1ce08fc14116c0e21794..848298c8b805a47f7ab4f9aa0773b71910dd763d 100644 (file)
@@ -146,13 +146,19 @@ AutomationTimeAxisView::AutomationTimeAxisView (
        ARDOUR_UI::instance()->set_tip(auto_button, _("automation state"));
        ARDOUR_UI::instance()->set_tip(hide_button, _("hide track"));
 
-       string str = gui_property ("height");
+       const string str = gui_property ("height");
        if (!str.empty()) {
                set_height (atoi (str));
        } else {
                set_height (preset_height (HeightNormal));
        }
 
+       /* repack the name label */
+
+       if (name_label.get_parent()) {
+               name_label.get_parent()->remove (name_label);
+       }
+       
        name_label.set_text (_name);
        name_label.set_alignment (Gtk::ALIGN_CENTER, Gtk::ALIGN_CENTER);
         name_label.set_name (X_("TrackParameterName"));
@@ -192,8 +198,9 @@ AutomationTimeAxisView::AutomationTimeAxisView (
        /* ask for notifications of any new RegionViews */
        if (show_regions) {
 
-               assert(_view);
-               _view->attach ();
+               if (_view) {
+                       _view->attach ();
+               }
 
        } else {
                /* no regions, just a single line for the entire track (e.g. bus gain) */
@@ -706,9 +713,7 @@ AutomationTimeAxisView::clear_lines ()
 void
 AutomationTimeAxisView::add_line (boost::shared_ptr<AutomationLine> line)
 {
-       assert(line);
-       assert(!_line);
-       if (_control) {
+       if (_control && line) {
                assert(line->the_list() == _control->list());
                
                _control->alist()->automation_state_changed.connect (