Subversion Repositories tpanel

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 andreas 1
/*
21 andreas 2
 * Copyright (C) 2020, 2021 by Andreas Theofilu <andreas@theosys.at>
2 andreas 3
 *
4
 * This program is free software; you can redistribute it and/or modify
5
 * it under the terms of the GNU General Public License as published by
6
 * the Free Software Foundation; either version 3 of the License, or
7
 * (at your option) any later version.
8
 *
9
 * This program is distributed in the hope that it will be useful,
10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
 * GNU General Public License for more details.
13
 *
14
 * You should have received a copy of the GNU General Public License
15
 * along with this program; if not, write to the Free Software Foundation,
16
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
17
 */
18
 
19
#ifndef __TQTSETTINGS_H__
20
#define __TQTSETTINGS_H__
21
 
22
#include <QDialog>
23
 
24
namespace Ui
25
{
26
	class TQtSettings;
27
}
28
 
29
class TQtSettings : public QDialog
30
{
31
	Q_OBJECT
32
 
33
	public:
34
		explicit TQtSettings(QWidget *parent = nullptr);
35
		~TQtSettings();
23 andreas 36
        bool hasChanged() { return mSetChanged; }
40 andreas 37
        void setScaleFactor(double sf) { mScaleFactor = sf; }
38
        void doResize();
59 andreas 39
        uint getLogLevel() { return mLogLevel; }
2 andreas 40
 
22 andreas 41
    private slots:
43 andreas 42
        void on_kiconbutton_logFile_clicked();
43
        void on_lineEdit_logFile_textChanged(const QString &arg1);
23 andreas 44
        void on_lineEdit_Controller_textChanged(const QString &arg1);
45
        void on_spinBox_Port_valueChanged(int arg1);
46
        void on_spinBox_Channel_valueChanged(int arg1);
47
        void on_lineEdit_PType_textChanged(const QString &arg1);
48
        void on_checkBox_Format_toggled(bool checked);
24 andreas 49
        void on_checkBox_Scale_toggled(bool checked);
35 andreas 50
        void on_checkBox_Profiling_toggled(bool checked);
59 andreas 51
        void on_checkBox_LogInfo_toggled(bool checked);
52
        void on_checkBox_LogWarning_toggled(bool checked);
53
        void on_checkBox_LogError_toggled(bool checked);
54
        void on_checkBox_LogTrace_toggled(bool checked);
55
        void on_checkBox_LogDebug_toggled(bool checked);
56
        void on_checkBox_LogProtocol_toggled(bool checked);
57
        void on_checkBox_LogAll_toggled(bool checked);
35 andreas 58
 
43 andreas 59
        void on_kiconbutton_reset_clicked();
60
 
22 andreas 61
    private:
43 andreas 62
        int scale(int value);
23 andreas 63
 
64
        Ui::TQtSettings *ui{nullptr};
65
        bool mSetChanged{false};
40 andreas 66
        double mScaleFactor{1.0};
59 andreas 67
        uint mLogLevel{0};
68
        bool mInitRun{false};
2 andreas 69
};
70
 
71
#endif