2012-05-26 14:49:10 +02:00
|
|
|
//=============================================================================
|
|
|
|
// MusE Score
|
|
|
|
// Linux Music Score Editor
|
|
|
|
//
|
2016-06-30 15:34:02 +02:00
|
|
|
// Copyright (C) 2002-2016 Werner Schweer and others
|
2012-05-26 14:49:10 +02:00
|
|
|
//
|
|
|
|
// This program is free software; you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License version 2.
|
|
|
|
//
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
|
|
// along with this program; if not, write to the Free Software
|
|
|
|
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
|
|
//=============================================================================
|
|
|
|
|
|
|
|
#ifndef __SYNTHCONTROL_H__
|
|
|
|
#define __SYNTHCONTROL_H__
|
|
|
|
|
|
|
|
#include "ui_synthcontrol.h"
|
2014-11-24 20:23:01 +01:00
|
|
|
#include "enableplayforwidget.h"
|
2012-05-26 14:49:10 +02:00
|
|
|
|
2013-05-13 18:49:17 +02:00
|
|
|
namespace Ms {
|
|
|
|
|
2012-05-26 14:49:10 +02:00
|
|
|
class Score;
|
|
|
|
|
|
|
|
//---------------------------------------------------------
|
|
|
|
// SynthControl
|
|
|
|
//---------------------------------------------------------
|
|
|
|
|
|
|
|
class SynthControl : public QWidget, Ui::SynthControl {
|
|
|
|
Q_OBJECT
|
|
|
|
|
2013-04-02 20:46:07 +02:00
|
|
|
Score* _score;
|
2014-11-24 20:23:01 +01:00
|
|
|
EnablePlayForWidget* enablePlay;
|
2019-06-08 18:09:44 +02:00
|
|
|
bool _dirty { false };
|
2014-11-24 20:23:01 +01:00
|
|
|
|
2012-05-26 14:49:10 +02:00
|
|
|
virtual void closeEvent(QCloseEvent*);
|
2014-11-24 20:23:01 +01:00
|
|
|
virtual void showEvent(QShowEvent*);
|
|
|
|
virtual bool eventFilter(QObject*, QEvent*);
|
|
|
|
virtual void keyPressEvent(QKeyEvent*) override;
|
2013-04-19 21:13:52 +02:00
|
|
|
void updateGui();
|
2016-07-16 19:44:28 +02:00
|
|
|
void readSettings();
|
2018-12-22 11:43:23 +01:00
|
|
|
void updateExpressivePatches();
|
|
|
|
void updateMixer();
|
|
|
|
void setAllUserBankController(bool val);
|
2012-05-26 14:49:10 +02:00
|
|
|
|
|
|
|
private slots:
|
|
|
|
void gainChanged(double, int);
|
|
|
|
void masterTuningChanged(double);
|
2013-04-19 17:15:30 +02:00
|
|
|
void changeMasterTuning();
|
2013-04-02 20:46:07 +02:00
|
|
|
void effectAChanged(int);
|
|
|
|
void effectBChanged(int);
|
|
|
|
void loadButtonClicked();
|
|
|
|
void saveButtonClicked();
|
2013-04-19 17:15:30 +02:00
|
|
|
void storeButtonClicked();
|
|
|
|
void recallButtonClicked();
|
2018-12-22 11:43:23 +01:00
|
|
|
void dynamicsMethodChanged(int);
|
|
|
|
void ccToUseChanged(int);
|
|
|
|
void switchExprButtonClicked();
|
|
|
|
void switchNonExprButtonClicked();
|
|
|
|
void resetExprButtonClicked();
|
2013-04-19 17:15:30 +02:00
|
|
|
void setDirty();
|
2012-05-26 14:49:10 +02:00
|
|
|
|
|
|
|
signals:
|
2013-04-03 12:13:23 +02:00
|
|
|
void soundFontChanged();
|
2013-05-12 23:13:28 +02:00
|
|
|
void closed(bool);
|
2012-05-26 14:49:10 +02:00
|
|
|
|
2016-06-30 15:34:02 +02:00
|
|
|
protected:
|
|
|
|
virtual void changeEvent(QEvent *event);
|
|
|
|
void retranslate() { retranslateUi(this); }
|
|
|
|
|
2012-05-26 14:49:10 +02:00
|
|
|
public slots:
|
|
|
|
void setGain(float);
|
|
|
|
|
|
|
|
public:
|
|
|
|
SynthControl(QWidget* parent);
|
|
|
|
void setMeter(float, float, float, float);
|
|
|
|
void stop();
|
2018-07-07 14:22:38 +02:00
|
|
|
void setScore(Score* s);
|
2013-07-12 14:22:20 +02:00
|
|
|
void writeSettings();
|
2012-05-26 14:49:10 +02:00
|
|
|
};
|
2013-05-13 18:49:17 +02:00
|
|
|
}
|
2012-05-26 14:49:10 +02:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|