summaryrefslogtreecommitdiff
path: root/gtk2_ardour/audio_time_axis.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2019-04-10 21:03:08 +0200
committerRobin Gareus <robin@gareus.org>2019-04-10 21:50:55 +0200
commitf5bc64d00e898ae02e3964f530155d8130584967 (patch)
tree1584e473013e010b6e7c74ae9bee161ad952c7f8 /gtk2_ardour/audio_time_axis.cc
parentd465a2b0124468a085e0a78898279f167095fdc1 (diff)
Add option to leave vertical gap below audio regions
This is a backport from Mixbus, to leave are 4 "open" pixels at the bottom of the track so one can see the grid-lines between tracks. This is useful with low region-transparency. grid-lines behind opaque regions are not visible.
Diffstat (limited to 'gtk2_ardour/audio_time_axis.cc')
-rw-r--r--gtk2_ardour/audio_time_axis.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/gtk2_ardour/audio_time_axis.cc b/gtk2_ardour/audio_time_axis.cc
index 72af2f846c..d67edd7aea 100644
--- a/gtk2_ardour/audio_time_axis.cc
+++ b/gtk2_ardour/audio_time_axis.cc
@@ -51,6 +51,7 @@
#include "public_editor.h"
#include "audio_region_view.h"
#include "audio_streamview.h"
+#include "ui_config.h"
#include "utils.h"
#include "pbd/i18n.h"
@@ -67,6 +68,7 @@ AudioTimeAxisView::AudioTimeAxisView (PublicEditor& ed, Session* sess, ArdourCan
: SessionHandlePtr (sess)
, RouteTimeAxisView(ed, sess, canvas)
{
+ UIConfiguration::instance().ParameterChanged.connect (sigc::mem_fun (*this, &AudioTimeAxisView::parameter_changed));
}
void
@@ -278,6 +280,14 @@ AudioTimeAxisView::route_active_changed ()
update_control_names ();
}
+void
+AudioTimeAxisView::parameter_changed (string const & p)
+{
+ if (p == "vertical-region-gap") {
+ _view->update_contents_height ();
+ }
+}
+
/**
* Set up the names of the controls so that they are coloured