/[svn]/qsampler/trunk/src/qsamplerOptions.h
ViewVC logotype

Annotation of /qsampler/trunk/src/qsamplerOptions.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1464 - (hide annotations) (download) (as text)
Thu Nov 1 17:14:21 2007 UTC (16 years, 5 months ago) by capela
File MIME type: text/x-c++hdr
File size: 3310 byte(s)
- Qt4 migration: missing copyright headers update.

1 capela 102 // qsamplerOptions.h
2     //
3     /****************************************************************************
4 schoenebeck 1461 Copyright (C) 2004-2007, rncbc aka Rui Nuno Capela. All rights reserved.
5 capela 1464 Copyright (C) 2007, Christian Schoenebeck
6 capela 102
7     This program is free software; you can redistribute it and/or
8     modify it under the terms of the GNU General Public License
9     as published by the Free Software Foundation; either version 2
10     of the License, or (at your option) any later version.
11    
12     This program is distributed in the hope that it will be useful,
13     but WITHOUT ANY WARRANTY; without even the implied warranty of
14     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15     GNU General Public License for more details.
16    
17 capela 920 You should have received a copy of the GNU General Public License along
18     with this program; if not, write to the Free Software Foundation, Inc.,
19     51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20 capela 102
21     *****************************************************************************/
22    
23     #ifndef __qsamplerOptions_h
24     #define __qsamplerOptions_h
25    
26     #include <qsettings.h>
27 schoenebeck 1461 #include <QStringList>
28 capela 102
29     class QWidget;
30     class QComboBox;
31    
32    
33     //-------------------------------------------------------------------------
34     // qsamplerOptions - Prototype settings class.
35     //
36    
37     class qsamplerOptions
38     {
39     public:
40    
41     // Constructor.
42     qsamplerOptions();
43     // Default destructor.
44     ~qsamplerOptions();
45    
46     // The settings object accessor.
47     QSettings& settings();
48    
49     // Command line arguments parser.
50     bool parse_args(int argc, char **argv);
51     // Command line usage helper.
52     void print_usage(const char *arg0);
53    
54     // Startup supplied session file.
55     QString sSessionFile;
56    
57     // Server options...
58     QString sServerHost;
59     int iServerPort;
60     int iServerTimeout;
61     bool bServerStart;
62     QString sServerCmdLine;
63     int iStartDelay;
64    
65     // Display options...
66     QString sDisplayFont;
67 capela 267 bool bDisplayEffect;
68 capela 102 bool bAutoRefresh;
69     int iAutoRefreshTime;
70 capela 119 int iMaxVolume;
71 capela 102 QString sMessagesFont;
72     bool bMessagesLimit;
73     int iMessagesLimitLines;
74     bool bConfirmRemove;
75 capela 454 bool bKeepOnTop;
76 capela 102 bool bStdoutCapture;
77     bool bCompletePath;
78 capela 341 bool bInstrumentNames;
79 capela 102
80     // View options...
81     bool bMenubar;
82     bool bToolbar;
83     bool bStatusbar;
84     bool bAutoArrange;
85    
86     // Default options...
87     QString sSessionDir;
88     QString sInstrumentDir;
89 capela 176 QString sEngineName;
90     QString sAudioDriver;
91     QString sMidiDriver;
92 capela 980 int iMidiMap;
93     int iMidiBank;
94     int iMidiProg;
95     int iVolume;
96     int iLoadMode;
97 capela 102
98     // Recent file list.
99     int iMaxRecentFiles;
100     QStringList recentFiles;
101    
102     // Widget geometry persistence helper prototypes.
103     void saveWidgetGeometry(QWidget *pWidget);
104     void loadWidgetGeometry(QWidget *pWidget);
105    
106     // Combo box history persistence helper prototypes.
107     void add2ComboBoxHistory(QComboBox *pComboBox, const QString& sNewText, int iLimit = 8, int iIndex = -1);
108     void loadComboBoxHistory(QComboBox *pComboBox, int iLimit = 8);
109     void saveComboBoxHistory(QComboBox *pComboBox, int iLimit = 8);
110    
111     private:
112    
113     // Settings member variables.
114     QSettings m_settings;
115     };
116    
117    
118     #endif // __qsamplerOptions_h
119    
120    
121     // end of qsamplerOptions.h

  ViewVC Help
Powered by ViewVC