Skip to content

Commit 3c3441b

Browse files
Faders with a dB scale (instead of linear/percentage) (LMMS#7636)
* Use dbFS scale for the faders Make the faders use a linear dbFS scale. They now also change position on first click and can then be dragged. The `Fader` class now has a new property called `m_faderMinDb`. It's the minimum value before the amplification drops down fully to 0. It is needed because we cannot represent a scale from -inf to maxDB. Rename `knobPosY` to `calculateKnobPosYFromModel` and move the implementation into the cpp file. The method now first converts the model's current amplification value to dbFS and then computes a ratio based on that values and the minimum and maximum dbFS values. Add the method `setVolumeByLocalPixelValue` which takes a local y coordinate of the widget and sets the amplification of the model based on a dbFS scale. Adjust `mousePressEvent` and `mouseMoveEvent` so that they mostly take the local y coordinate of the event and use that to adjust the model via `setVolumeByLocalPixelValue`. Remove `m_moveStartPoint` and `m_startValue` and they are not needed anymore. * Apply curve to faders Apply a curve, i.e. the cube function and its inverse, to the fader positions to that we have more space to work with in the "interesting" areas around 0 dB and less space in the area where we tend to "-inf dB". Set the minimum dB value of the fader to -120 dB to increase the potential headroom. * Support for dB models Add support for models that are in dB. There's a new member `m_modelIsLinear` which can be set via the constructor. The default value in the constructor is `true`. Add the method `modelIsLinear` which can be used to query the parameter. It is used in `calculateKnobPosYFromModel` and `setVolumeByLocalPixelValue`. Both methods got extended to deal with models in dB. They were also refactored to extract code that is common for both cases. Ensure that the constructor of `Fader` is called with `false` for `CrossoverEQControlDialog` and `EqFader` because these use models that are in dB. * Show current dB value of fader in tool tip Show the current value of the fader in its tool tip. Please note that this value is always shown in dB because the goal should be to get rid of the linear values for the faders. Some of the code is extracted into the new method `Fader::getModelValueAsDbString` which is shared by `Fader::modelValueChanged` (also new) and `Fader::updateTextFloat`. Please note that `getModelValueAsDbString` will use "dB" instead of "dBFS" as the unit and that it will format "-inf dB" instead of "-∞ dB". These changes will also be visible in the text float that is used to show the new values as the fader is being dragged. * Let users enter values in dB Let users enter values in dB in the dialog that opens with a double click. The minimum value that can be entered is the minimum value that the fader allows to set, i.e. -120 dB. The maximum value is the maximum value of the model converted to dB. As of now this is ~6 dB. The current value is converted to dB. If it corresponds to "-inf dB", i.e. if the amplification is 0 then the minimum value is used. * Remove option "Display volume as dBFS" Remove the option "Display volume as dBFS" from the settings dialog and the check box option "Volume as dBFS" from the "View" menu. Volumes are now always treated as dB, i.e. all evaluations of the property "displaydbfs" have been removed which results in assuming that this option is always true. The upgrade code in `ConfigManager::upgrade_1_1_91` was left as is. However, a note was added which informs the reader that the value of "displaydbfs" is not evaluated anymore. * Extend Fader::wheelEvent Extend `Fader::wheelEvent` for the case where the model is not a dB model (`modelIsLinear() == true`), e.g. for the mixer faders. In that case it works as follows. Each step increments or decrements by 1 dB if no modifier is pressed. With "Shift" pressed the increment value is 3 dB. With "STRG" ("CTRL") pressed the increment value is reduced to 0.1 dB. If the value goes below the minimum positive dB value that is allowed by the fader then the fader is set to "-inf dB", i.e. zero amplification. If the fader is set to "-inf dB" and the users want to increase the value then it is first set to the minimum positive value that is allowed by the fader. If the model is a dB model then the same behavior as before is used. Although it should be considered to adjust this case as well. These models are used by the faders of the Crossover Equalizer, Equalizer, Compressor and Delay and they are not very usable with the mouse wheel. * Adjust the wheel behavior for faders with dB models Make the faders of the Crossover Equalizer, Equalizer, Compressor and Delay behave like the mixer faders, i.e. step in sizes of 3 dB, 1dB and 0.1 dB depending on whether a modifier key is pressed or not. Extract some common code to do so and add some `const` keywords. * Less "jumpy" knobs Implement a more stable knob behavior. Remove the jumping behavior if the users directly click on a volume knob. By storing the offset from the knob center and taking it into account during the changes it now also feels like the users are dragging the knob. Changes to the amplification are now only applied when the mouse is moved. This makes the double click behavior much more stable, i.e. if users click on the knob when it is at 0 dB the dialog will also show 0 dB and not something like 0.3 dB because the first click is already registered as a change of volume. If the users click next to the knob the amplification will still be changed immediately to that value. ## Technical details To make the knobs more stable a variable called `m_knobCenterOffset` was introduced. It stores the offset of the click from the knob center so that this value can be taken into account for in the method `setVolumeByLocalPixelValue`. * Make MSVC happy Add an indication that a float value is assigned to a float variable. * Introduce constexpr for scaling exponent Introduce the `constexpr c_dBScalingExponent` which describes the scaling exponent that's used to scale the dB scale in both directions. This will simplify potential adjustments by keeping the values consistent everywhere. * Draw fader ticks Draw fader ticks in case the model is a linear one. This means that for now they should only be painted for the mixer faders but not for the faders of the Compressor, Delay, etc. Extract the computation of the scaled ratio between the maximum model dB value and the minimum supported fader dB value into the new private method `computeScaledRatio`. This is necessary because it is needed to paint the fader knob at the correct position (using the knob bottom as the reference) and to paint the fader ticks at the correct position (using the knob center). Introduce the private method `paintFaderTicks` which paints the fader ticks. Note: to paint some non-evenly spaced fader ticks replace the `for` expression in `paintFaderTicks` with something like the following: ``` for (auto & i : {6.f, 0.f, -6.f, -12.f, -24.f, -36.f, -48.f, -60.f, -72.f, -84.f, -96.f, -108.f, -120.f}) ``` * Fader adjustments via keyboard Allow the adjustment of the faders via the keyboard. Using the up or plus key will increment the fader value whereas the down or minus key will decrement it. The same key modifiers as for the wheel event apply: * No modifier: adjust by 1 dB * Shift: adjust by 3 dB * Control: adjust by 0.1 dB Due to the very similar behavior of the mouse wheel and key press handling some common functionality was factored out: * Determinination of the (absolute) adjustment delta value by insprecting the modifier keys of an event. Factored into `determineAdjustmentDelta`. * Adjustment of the model by a given dB delta value. Factored into `adjustModelByDBDelta`. * Move the fader of the selected channel Move the fader of the selected channel instead of the fader that has focus when the up/plus or down/minus keys are pressed. Doing so also feels more natural because users can already change the selected channel via the left and right keys and now they can immediately adjust the volume of the currently selected channel while doing so. Key events are now handled in `MixerView::keyPressEvent` instead of `Fader::keyPressEvent` and the latter is removed. `MixerChannelView` now has a method called `fader` which provides the associated fader. This is needed so that the event handler of `MixerView` can act upon the currently selected fader. ## Changes in Fader The `Fader` class provides two new public methods. The `adjust` method takes the modifier key(s) and the adjustment direction and then decides internally how the modifier keys are mapped to increment values. This is done to keep the mapping between modifier keys and increment values consistent across different clients, e.g. the key event of the `MixerView` and the wheel event of the `Fader` itself. The direction is provided by the client because the means to determine the direction can differ between clients and cases, e.g. a wheel event determines the direction differently than a key event does. The method `adjustByDecibelDelta` simply adjusts the fader by the given delta amount. It currently is not really used in a public way but it still makes sense to provide this functionality in case a parent class or client wants to manipulate the faders by its very own logic. Because the `Fader` class does not react itself to key press events anymore the call to `setFocusPolicy` is removed again. * Enter fader value when space key pressed Let the users enter the fader value via dialog when the space key is pressed. Extract the dialog logic into the new method `adjustByDialog` and call it from `MixerView::keyPressEvent`. Make `Fader::mouseDoubleClickEvent` delegate to `adjustByDialog` and also fix the behavior by accepting the event. * More prominent fader ticks around 0 dB Make the fader ticks around 0 dB more prominent but drawing them slightly wider and with a more opaque color. * Work around a Qt bug Work around a Qt bug in conjunction with the scroll wheel and the Alt key. Simply return 0 for the fader delta as soon as Alt is pressed. * Fix wheel events without any modifier Fix the handling of wheel events without any modifier key being pressed. Commit ff435d5 accidentally tested against Alt using a logical OR instead of an AND. * Code review changes First set of code review changes: * Use Doxygen style documentation comments * Remove comment about `displaydbfs` from upgrade routine * White-space changes for touched lines. * Make minimum dB value a constexpr Make the minimum dB value a constexpr in the implementation file because currently it's an implementation detail that should not be of any interest to any other client. So `m_faderMinDb` becomes `c_faderMinDb`. * More flexible painting of fader ticks Paint the fader ticks in a more systematic and flexible way. This also removes some "magic numbers", e.g. by using `c_faderMinDb` instead of `-120.f` as the lower limit. The upper limit, i.e. the "starting point" is now also computed using the maximum value of the model so that the fader will still paint correctly if it ever changes. * Make the zero indicator bolder Make the zero indicator tick of the fader bolder. * Make rendering of fader ticks a preference Make rendering of fader ticks a preference which is off by default. Introduce the new option "Show fader ticks" to the setup dialog and save it to the UI attribute `showfaderticks`. The configuration value is currently evaluated in `Fader::paintEvent`. If this leads to performance problems it might be better to introduce a boolean member to the `Fader` class which caches that value. * Move constexprs to anonymous namespace
1 parent 3417dfe commit 3c3441b

File tree

10 files changed

+449
-96
lines changed

10 files changed

+449
-96
lines changed

include/Fader.h

Lines changed: 46 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ class LMMS_EXPORT Fader : public QWidget, public FloatModelView
7474
Q_PROPERTY(bool renderUnityLine READ getRenderUnityLine WRITE setRenderUnityLine)
7575
Q_PROPERTY(QColor unityMarker MEMBER m_unityMarker)
7676

77-
Fader(FloatModel* model, const QString& name, QWidget* parent);
78-
Fader(FloatModel* model, const QString& name, QWidget* parent, const QPixmap& knob);
77+
Fader(FloatModel* model, const QString& name, QWidget* parent, bool modelIsLinear = true);
78+
Fader(FloatModel* model, const QString& name, QWidget* parent, const QPixmap& knob, bool modelIsLinear = true);
7979
~Fader() override = default;
8080

8181
void setPeak_L(float fPeak);
@@ -93,6 +93,17 @@ class LMMS_EXPORT Fader : public QWidget, public FloatModelView
9393
inline bool getRenderUnityLine() const { return m_renderUnityLine; }
9494
inline void setRenderUnityLine(bool value = true) { m_renderUnityLine = value; }
9595

96+
enum class AdjustmentDirection
97+
{
98+
Up,
99+
Down
100+
};
101+
102+
void adjust(const Qt::KeyboardModifiers & modifiers, AdjustmentDirection direction);
103+
void adjustByDecibelDelta(float value);
104+
105+
void adjustByDialog();
106+
96107
void setDisplayConversion(bool b)
97108
{
98109
m_conversionFactor = b ? 100.0 : 1.0;
@@ -118,18 +129,34 @@ class LMMS_EXPORT Fader : public QWidget, public FloatModelView
118129
void paintEvent(QPaintEvent* ev) override;
119130

120131
void paintLevels(QPaintEvent* ev, QPainter& painter, bool linear = false);
121-
122-
int knobPosY() const
123-
{
124-
float fRange = model()->maxValue() - model()->minValue();
125-
float realVal = model()->value() - model()->minValue();
126-
127-
return height() - ((height() - m_knob.height()) * (realVal / fRange));
128-
}
132+
void paintFaderTicks(QPainter& painter);
133+
134+
float determineAdjustmentDelta(const Qt::KeyboardModifiers & modifiers) const;
135+
void adjustModelByDBDelta(float value);
136+
137+
int calculateKnobPosYFromModel() const;
138+
void setVolumeByLocalPixelValue(int y);
139+
140+
/**
141+
* @brief Computes the scaled ratio between the maximum dB value supported by the model and the minimum
142+
* dB value that's supported by the fader from the given actual dB value.
143+
*
144+
* If the provided input value lies inside the aforementioned interval then the result will be
145+
* a value between 0 (value == minimum value) and 1 (value == maximum model value).
146+
* If you look at the graphical representation of the fader then 0 represents a point at the bottom
147+
* of the fader and 1 a point at the top of the fader.
148+
* The ratio is scaled by an internal exponent which is an implementation detail that cannot be
149+
* changed for now.
150+
*/
151+
float computeScaledRatio(float dBValue) const;
129152

130153
void setPeak(float fPeak, float& targetPeak, float& persistentPeak, QElapsedTimer& lastPeakTimer);
131154

132155
void updateTextFloat();
156+
void modelValueChanged();
157+
QString getModelValueAsDbString() const;
158+
159+
bool modelIsLinear() const { return m_modelIsLinear; }
133160

134161
// Private members
135162
private:
@@ -145,10 +172,16 @@ class LMMS_EXPORT Fader : public QWidget, public FloatModelView
145172

146173
QPixmap m_knob {embed::getIconPixmap("fader_knob")};
147174

148-
bool m_levelsDisplayedInDBFS {true};
175+
/**
176+
* @brief Stores the offset to the knob center when the user drags the fader knob
177+
*
178+
* This is needed to make it feel like the users drag the knob without it
179+
* jumping immediately to the click position.
180+
*/
181+
int m_knobCenterOffset {0};
149182

150-
int m_moveStartPoint {-1};
151-
float m_startValue {0.};
183+
bool m_levelsDisplayedInDBFS {true};
184+
bool m_modelIsLinear {false};
152185

153186
static SimpleTextFloat* s_textFloat;
154187

include/MixerChannelView.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,8 @@ class MixerChannelView : public QWidget
8282
QColor strokeInnerInactive() const { return m_strokeInnerInactive; }
8383
void setStrokeInnerInactive(const QColor& c) { m_strokeInnerInactive = c; }
8484

85+
Fader* fader() const { return m_fader; }
86+
8587
public slots:
8688
void renameChannel();
8789
void resetColor();

include/SetupDialog.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,10 +72,10 @@ protected slots:
7272

7373
private slots:
7474
// General settings widget.
75-
void toggleDisplaydBFS(bool enabled);
7675
void toggleTooltips(bool enabled);
7776
void toggleDisplayWaveform(bool enabled);
7877
void toggleNoteLabels(bool enabled);
78+
void toggleShowFaderTicks(bool enabled);
7979
void toggleCompactTrackButtons(bool enabled);
8080
void toggleOneInstrumentTrackWindow(bool enabled);
8181
void toggleSideBarOnRight(bool enabled);
@@ -134,10 +134,10 @@ private slots:
134134
TabBar * m_tabBar;
135135

136136
// General settings widgets.
137-
bool m_displaydBFS;
138137
bool m_tooltips;
139138
bool m_displayWaveform;
140139
bool m_printNoteLabels;
140+
bool m_showFaderTicks;
141141
bool m_compactTrackButtons;
142142
bool m_oneInstrumentTrackWindow;
143143
bool m_sideBarOnRight;

plugins/CrossoverEQ/CrossoverEQControlDialog.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,25 +70,25 @@ CrossoverEQControlDialog::CrossoverEQControlDialog( CrossoverEQControls * contro
7070
QPixmap const fader_knob(PLUGIN_NAME::getIconPixmap("fader_knob2"));
7171

7272
// faders
73-
auto gain1 = new Fader(&controls->m_gain1, tr("Band 1 gain"), this, fader_knob);
73+
auto gain1 = new Fader(&controls->m_gain1, tr("Band 1 gain"), this, fader_knob, false);
7474
gain1->move( 7, 56 );
7575
gain1->setDisplayConversion( false );
7676
gain1->setHintText( tr( "Band 1 gain:" ), " dBFS" );
7777
gain1->setRenderUnityLine(false);
7878

79-
auto gain2 = new Fader(&controls->m_gain2, tr("Band 2 gain"), this, fader_knob);
79+
auto gain2 = new Fader(&controls->m_gain2, tr("Band 2 gain"), this, fader_knob, false);
8080
gain2->move( 47, 56 );
8181
gain2->setDisplayConversion( false );
8282
gain2->setHintText( tr( "Band 2 gain:" ), " dBFS" );
8383
gain2->setRenderUnityLine(false);
8484

85-
auto gain3 = new Fader(&controls->m_gain3, tr("Band 3 gain"), this, fader_knob);
85+
auto gain3 = new Fader(&controls->m_gain3, tr("Band 3 gain"), this, fader_knob, false);
8686
gain3->move( 87, 56 );
8787
gain3->setDisplayConversion( false );
8888
gain3->setHintText( tr( "Band 3 gain:" ), " dBFS" );
8989
gain3->setRenderUnityLine(false);
9090

91-
auto gain4 = new Fader(&controls->m_gain4, tr("Band 4 gain"), this, fader_knob);
91+
auto gain4 = new Fader(&controls->m_gain4, tr("Band 4 gain"), this, fader_knob, false);
9292
gain4->move( 127, 56 );
9393
gain4->setDisplayConversion( false );
9494
gain4->setHintText( tr( "Band 4 gain:" ), " dBFS" );

plugins/Eq/EqFader.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class EqFader : public Fader
4343
Q_OBJECT
4444
public:
4545
EqFader( FloatModel * model, const QString & name, QWidget * parent, float* lPeak, float* rPeak ) :
46-
Fader( model, name, parent )
46+
Fader(model, name, parent, false)
4747
{
4848
setMinimumSize( 23, 116 );
4949
setMaximumSize( 23, 116 );

src/gui/MainWindow.cpp

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,13 +1099,7 @@ void MainWindow::updateViewMenu()
10991099
// Here we should put all look&feel -stuff from configmanager
11001100
// that is safe to change on the fly. There is probably some
11011101
// more elegant way to do this.
1102-
auto qa = new QAction(tr("Volume as dBFS"), this);
1103-
qa->setData("displaydbfs");
1104-
qa->setCheckable( true );
1105-
qa->setChecked( ConfigManager::inst()->value( "app", "displaydbfs" ).toInt() );
1106-
m_viewMenu->addAction(qa);
1107-
1108-
qa = new QAction(tr( "Smooth scroll" ), this);
1102+
auto qa = new QAction(tr("Smooth scroll"), this);
11091103
qa->setData("smoothscroll");
11101104
qa->setCheckable( true );
11111105
qa->setChecked( ConfigManager::inst()->value( "ui", "smoothscroll" ).toInt() );
@@ -1135,12 +1129,7 @@ void MainWindow::updateConfig( QAction * _who )
11351129
QString tag = _who->data().toString();
11361130
bool checked = _who->isChecked();
11371131

1138-
if( tag == "displaydbfs" )
1139-
{
1140-
ConfigManager::inst()->setValue( "app", "displaydbfs",
1141-
QString::number(checked) );
1142-
}
1143-
else if ( tag == "tooltips" )
1132+
if (tag == "tooltips")
11441133
{
11451134
ConfigManager::inst()->setValue( "tooltips", "disabled",
11461135
QString::number(!checked) );

src/gui/MixerView.cpp

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -481,6 +481,16 @@ void MixerView::renameChannel(int index)
481481

482482
void MixerView::keyPressEvent(QKeyEvent * e)
483483
{
484+
auto adjustCurrentFader = [this](const Qt::KeyboardModifiers& modifiers, Fader::AdjustmentDirection direction)
485+
{
486+
auto* mixerChannel = currentMixerChannel();
487+
488+
if (mixerChannel)
489+
{
490+
mixerChannel->fader()->adjust(modifiers, direction);
491+
}
492+
};
493+
484494
switch(e->key())
485495
{
486496
case Qt::Key_Delete:
@@ -508,6 +518,14 @@ void MixerView::keyPressEvent(QKeyEvent * e)
508518
setCurrentMixerChannel(m_currentMixerChannel->channelIndex() + 1);
509519
}
510520
break;
521+
case Qt::Key_Up:
522+
case Qt::Key_Plus:
523+
adjustCurrentFader(e->modifiers(), Fader::AdjustmentDirection::Up);
524+
break;
525+
case Qt::Key_Down:
526+
case Qt::Key_Minus:
527+
adjustCurrentFader(e->modifiers(), Fader::AdjustmentDirection::Down);
528+
break;
511529
case Qt::Key_Insert:
512530
if (e->modifiers() & Qt::ShiftModifier)
513531
{
@@ -519,6 +537,16 @@ void MixerView::keyPressEvent(QKeyEvent * e)
519537
case Qt::Key_F2:
520538
renameChannel(m_currentMixerChannel->channelIndex());
521539
break;
540+
case Qt::Key_Space:
541+
{
542+
auto* mixerChannel = currentMixerChannel();
543+
544+
if (mixerChannel)
545+
{
546+
mixerChannel->fader()->adjustByDialog();
547+
}
548+
}
549+
break;
522550
}
523551
}
524552

src/gui/modals/SetupDialog.cpp

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -91,14 +91,14 @@ inline void labelWidget(QWidget * w, const QString & txt)
9191

9292

9393
SetupDialog::SetupDialog(ConfigTab tab_to_open) :
94-
m_displaydBFS(ConfigManager::inst()->value(
95-
"app", "displaydbfs").toInt()),
9694
m_tooltips(!ConfigManager::inst()->value(
9795
"tooltips", "disabled").toInt()),
9896
m_displayWaveform(ConfigManager::inst()->value(
9997
"ui", "displaywaveform").toInt()),
10098
m_printNoteLabels(ConfigManager::inst()->value(
10199
"ui", "printnotelabels").toInt()),
100+
m_showFaderTicks(ConfigManager::inst()->value(
101+
"ui", "showfaderticks").toInt()),
102102
m_compactTrackButtons(ConfigManager::inst()->value(
103103
"ui", "compacttrackbuttons").toInt()),
104104
m_oneInstrumentTrackWindow(ConfigManager::inst()->value(
@@ -231,14 +231,14 @@ SetupDialog::SetupDialog(ConfigTab tab_to_open) :
231231
QGroupBox * guiGroupBox = new QGroupBox(tr("Graphical user interface (GUI)"), generalControls);
232232
QVBoxLayout * guiGroupLayout = new QVBoxLayout(guiGroupBox);
233233

234-
addCheckBox(tr("Display volume as dBFS "), guiGroupBox, guiGroupLayout,
235-
m_displaydBFS, SLOT(toggleDisplaydBFS(bool)), true);
236234
addCheckBox(tr("Enable tooltips"), guiGroupBox, guiGroupLayout,
237235
m_tooltips, SLOT(toggleTooltips(bool)), true);
238236
addCheckBox(tr("Enable master oscilloscope by default"), guiGroupBox, guiGroupLayout,
239237
m_displayWaveform, SLOT(toggleDisplayWaveform(bool)), true);
240238
addCheckBox(tr("Enable all note labels in piano roll"), guiGroupBox, guiGroupLayout,
241239
m_printNoteLabels, SLOT(toggleNoteLabels(bool)), false);
240+
addCheckBox(tr("Show fader ticks"), guiGroupBox, guiGroupLayout,
241+
m_showFaderTicks, SLOT(toggleShowFaderTicks(bool)), false);
242242
addCheckBox(tr("Enable compact track buttons"), guiGroupBox, guiGroupLayout,
243243
m_compactTrackButtons, SLOT(toggleCompactTrackButtons(bool)), true);
244244
addCheckBox(tr("Enable one instrument-track-window mode"), guiGroupBox, guiGroupLayout,
@@ -913,14 +913,14 @@ void SetupDialog::accept()
913913
from taking mouse input, rendering the application unusable. */
914914
QDialog::accept();
915915

916-
ConfigManager::inst()->setValue("app", "displaydbfs",
917-
QString::number(m_displaydBFS));
918916
ConfigManager::inst()->setValue("tooltips", "disabled",
919917
QString::number(!m_tooltips));
920918
ConfigManager::inst()->setValue("ui", "displaywaveform",
921919
QString::number(m_displayWaveform));
922920
ConfigManager::inst()->setValue("ui", "printnotelabels",
923921
QString::number(m_printNoteLabels));
922+
ConfigManager::inst()->setValue("ui", "showfaderticks",
923+
QString::number(m_showFaderTicks));
924924
ConfigManager::inst()->setValue("ui", "compacttrackbuttons",
925925
QString::number(m_compactTrackButtons));
926926
ConfigManager::inst()->setValue("ui", "oneinstrumenttrackwindow",
@@ -1003,12 +1003,6 @@ void SetupDialog::accept()
10031003

10041004
// General settings slots.
10051005

1006-
void SetupDialog::toggleDisplaydBFS(bool enabled)
1007-
{
1008-
m_displaydBFS = enabled;
1009-
}
1010-
1011-
10121006
void SetupDialog::toggleTooltips(bool enabled)
10131007
{
10141008
m_tooltips = enabled;
@@ -1026,6 +1020,10 @@ void SetupDialog::toggleNoteLabels(bool enabled)
10261020
m_printNoteLabels = enabled;
10271021
}
10281022

1023+
void SetupDialog::toggleShowFaderTicks(bool enabled)
1024+
{
1025+
m_showFaderTicks = enabled;
1026+
}
10291027

10301028
void SetupDialog::toggleCompactTrackButtons(bool enabled)
10311029
{

0 commit comments

Comments
 (0)