Make arrow "stepper" buttons themeable and use SVG assets (#8123)
* SVG-ify arrow buttons These buttons are used in the instrument window, Vestige, and VST effects. Separate versions of the arrow icons are used for the classic theme. * Fix some unrelated SVG formatting and metadata * Revert accidental change to classic border radius * Add some XML stuff back to appease Github LMMS renders these SVGs just fine, but apparently the removal of the XML declaration completely breaks Github's ability to render the image, so I am adding these back for the sake of those who want to actually look at the diff on the website lmao * Attempt to fix Github SVG previews again (`xmlns`) * Fix crossover eq band mute button icon size You may ask, "what does this have to do with the arrow buttons?" and you would be right to assume this is unrelated. However, I'm already touching the relevant lines of the stylesheet so I may as well sneak it in there. * Add missing metadata to fader_knob.svg And fix mixed indentation in headphones.svg * Add missing `xmlns` to fader_knob.svg GRADIENTS!!!!!!!!!!!! * Fix classic theme arrow buttons The originals were right angle chevrons * Remove unused getters
This commit is contained in:
@@ -532,14 +532,10 @@ VestigeInstrumentView::VestigeInstrumentView( Instrument * _instrument,
|
||||
m_openPresetButton->setToolTip(tr("Open VST plugin preset"));
|
||||
|
||||
|
||||
m_rolLPresetButton = new PixmapButton( this, "" );
|
||||
m_rolLPresetButton->setCheckable( false );
|
||||
m_rolLPresetButton->setCursor( Qt::PointingHandCursor );
|
||||
m_rolLPresetButton = new QPushButton(this);
|
||||
m_rolLPresetButton->setObjectName("btn-stepper-left");
|
||||
m_rolLPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
m_rolLPresetButton->move( 190, 201 );
|
||||
m_rolLPresetButton->setActiveGraphic( embed::getIconPixmap(
|
||||
"stepper-left-press" ) );
|
||||
m_rolLPresetButton->setInactiveGraphic( embed::getIconPixmap(
|
||||
"stepper-left" ) );
|
||||
connect( m_rolLPresetButton, SIGNAL( clicked() ), this,
|
||||
SLOT( previousProgram() ) );
|
||||
m_rolLPresetButton->setToolTip(tr("Previous (-)"));
|
||||
@@ -560,14 +556,10 @@ VestigeInstrumentView::VestigeInstrumentView( Instrument * _instrument,
|
||||
m_savePresetButton->setToolTip(tr("Save preset"));
|
||||
|
||||
|
||||
m_rolRPresetButton = new PixmapButton( this, "" );
|
||||
m_rolRPresetButton->setCheckable( false );
|
||||
m_rolRPresetButton->setCursor( Qt::PointingHandCursor );
|
||||
m_rolRPresetButton = new QPushButton(this);
|
||||
m_rolRPresetButton->setObjectName("btn-stepper-right");
|
||||
m_rolRPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
m_rolRPresetButton->move( 209, 201 );
|
||||
m_rolRPresetButton->setActiveGraphic( embed::getIconPixmap(
|
||||
"stepper-right-press" ) );
|
||||
m_rolRPresetButton->setInactiveGraphic( embed::getIconPixmap(
|
||||
"stepper-right" ) );
|
||||
connect( m_rolRPresetButton, SIGNAL( clicked() ), this,
|
||||
SLOT( nextProgram() ) );
|
||||
m_rolRPresetButton->setToolTip(tr("Next (+)"));
|
||||
@@ -575,16 +567,15 @@ VestigeInstrumentView::VestigeInstrumentView( Instrument * _instrument,
|
||||
m_rolRPresetButton->setShortcut( Qt::Key_Plus );
|
||||
|
||||
|
||||
m_selPresetButton = new QPushButton( tr( "" ), this );
|
||||
m_selPresetButton->setGeometry( 228, 201, 16, 16 );
|
||||
m_selPresetButton = new QPushButton(this);
|
||||
m_selPresetButton->setObjectName("btn-stepper-down");
|
||||
m_selPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
m_selPresetButton->move(228, 201);
|
||||
|
||||
auto menu = new QMenu;
|
||||
|
||||
connect( menu, SIGNAL( aboutToShow() ), this, SLOT( updateMenu() ) );
|
||||
|
||||
|
||||
m_selPresetButton->setIcon( embed::getIconPixmap( "stepper-down" ) );
|
||||
|
||||
m_selPresetButton->setMenu(menu);
|
||||
|
||||
m_toggleGUIButton = new QPushButton( tr( "Show/hide GUI" ), this );
|
||||
|
||||
@@ -174,8 +174,8 @@ private:
|
||||
|
||||
PixmapButton * m_openPluginButton;
|
||||
PixmapButton * m_openPresetButton;
|
||||
PixmapButton * m_rolLPresetButton;
|
||||
PixmapButton * m_rolRPresetButton;
|
||||
QPushButton* m_rolLPresetButton;
|
||||
QPushButton* m_rolRPresetButton;
|
||||
QPushButton * m_selPresetButton;
|
||||
QPushButton * m_toggleGUIButton;
|
||||
PixmapButton * m_managePluginButton;
|
||||
|
||||
@@ -123,13 +123,9 @@ VstEffectControlDialog::VstEffectControlDialog( VstEffectControls * _ctl ) :
|
||||
m_openPresetButton->setMinimumHeight( 16 );
|
||||
m_openPresetButton->setMaximumHeight( 16 );
|
||||
|
||||
m_rolLPresetButton = new PixmapButton( this, "" );
|
||||
m_rolLPresetButton->setCheckable( false );
|
||||
m_rolLPresetButton->setCursor( Qt::PointingHandCursor );
|
||||
m_rolLPresetButton->setActiveGraphic( embed::getIconPixmap(
|
||||
"stepper-left-press" ) );
|
||||
m_rolLPresetButton->setInactiveGraphic( embed::getIconPixmap(
|
||||
"stepper-left" ) );
|
||||
m_rolLPresetButton = new QPushButton(this);
|
||||
m_rolLPresetButton->setObjectName("btn-stepper-left");
|
||||
m_rolLPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
connect( m_rolLPresetButton, SIGNAL( clicked() ), _ctl,
|
||||
SLOT( rolrPreset() ) );
|
||||
|
||||
@@ -140,18 +136,10 @@ VstEffectControlDialog::VstEffectControlDialog( VstEffectControls * _ctl ) :
|
||||
|
||||
m_rolLPresetButton->setShortcut( Qt::Key_Minus );
|
||||
|
||||
m_rolLPresetButton->setMinimumWidth( 16 );
|
||||
m_rolLPresetButton->setMaximumWidth( 16 );
|
||||
m_rolLPresetButton->setMinimumHeight( 16 );
|
||||
m_rolLPresetButton->setMaximumHeight( 16 );
|
||||
|
||||
m_rolRPresetButton = new PixmapButton( this, "" );
|
||||
m_rolRPresetButton->setCheckable( false );
|
||||
m_rolRPresetButton->setCursor( Qt::PointingHandCursor );
|
||||
m_rolRPresetButton->setActiveGraphic( embed::getIconPixmap(
|
||||
"stepper-right-press" ) );
|
||||
m_rolRPresetButton->setInactiveGraphic( embed::getIconPixmap(
|
||||
"stepper-right" ) );
|
||||
m_rolRPresetButton = new QPushButton(this);
|
||||
m_rolRPresetButton->setObjectName("btn-stepper-right");
|
||||
m_rolRPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
connect( m_rolRPresetButton, SIGNAL( clicked() ), _ctl,
|
||||
SLOT( rollPreset() ) );
|
||||
|
||||
@@ -162,16 +150,10 @@ VstEffectControlDialog::VstEffectControlDialog( VstEffectControls * _ctl ) :
|
||||
|
||||
m_rolRPresetButton->setShortcut( Qt::Key_Plus );
|
||||
|
||||
m_rolRPresetButton->setMinimumWidth( 16 );
|
||||
m_rolRPresetButton->setMaximumWidth( 16 );
|
||||
m_rolRPresetButton->setMinimumHeight( 16 );
|
||||
m_rolRPresetButton->setMaximumHeight( 16 );
|
||||
|
||||
_ctl->m_selPresetButton = new QPushButton( tr( "" ), this );
|
||||
|
||||
_ctl->m_selPresetButton->setCheckable( false );
|
||||
_ctl->m_selPresetButton->setCursor( Qt::PointingHandCursor );
|
||||
_ctl->m_selPresetButton->setIcon( embed::getIconPixmap( "stepper-down" ) );
|
||||
_ctl->m_selPresetButton = new QPushButton(this);
|
||||
_ctl->m_selPresetButton->setObjectName("btn-stepper-down");
|
||||
_ctl->m_selPresetButton->setCursor(Qt::PointingHandCursor);
|
||||
|
||||
auto menu = new QMenu;
|
||||
connect( menu, SIGNAL( aboutToShow() ), _ctl, SLOT( updateMenu() ) );
|
||||
@@ -299,4 +281,4 @@ void VstEffectControlDialog::togglePluginUI( bool checked )
|
||||
}
|
||||
|
||||
|
||||
} // namespace lmms::gui
|
||||
} // namespace lmms::gui
|
||||
|
||||
@@ -60,8 +60,8 @@ private:
|
||||
|
||||
QPushButton * m_togglePluginButton;
|
||||
PixmapButton * m_openPresetButton;
|
||||
PixmapButton * m_rolLPresetButton;
|
||||
PixmapButton * m_rolRPresetButton;
|
||||
QPushButton* m_rolLPresetButton;
|
||||
QPushButton* m_rolRPresetButton;
|
||||
PixmapButton * m_managePluginButton;
|
||||
PixmapButton * m_savePresetButton;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user