Browse Source

Set parameter tooltip based on lv2 control comment

tags/v2.1-rc1
falkTX 5 years ago
parent
commit
36e98b942a
2 changed files with 8 additions and 0 deletions
  1. +4
    -0
      source/frontend/carla_widgets.py
  2. +4
    -0
      source/frontend/widgets/paramspinbox.py

+ 4
- 0
source/frontend/carla_widgets.py View File

@@ -252,6 +252,10 @@ class PluginParameter(QWidget):
self.ui.widget.setStepLarge(pInfo['stepLarge'])
self.ui.widget.setScalePoints(pInfo['scalePoints'], bool(pHints & PARAMETER_USES_SCALEPOINTS))

if pInfo['comment']:
self.ui.label.setToolTip(pInfo['comment'])
self.ui.widget.setToolTip(pInfo['comment'])

if pType == PARAMETER_INPUT:
if not pHints & PARAMETER_IS_ENABLED:
self.ui.label.setEnabled(False)


+ 4
- 0
source/frontend/widgets/paramspinbox.py View File

@@ -441,6 +441,10 @@ class ParamSpinBox(QAbstractSpinBox):

self.fBox.currentIndexChanged['QString'].connect(self.slot_comboBoxIndexChanged)

def setToolTip(self, text):
self.fBar.setToolTip(text)
QAbstractSpinBox.setToolTip(self, text)

def stepBy(self, steps):
if steps == 0 or self.fValue is None:
return


Loading…
Cancel
Save