624
by cecilios
Initial update for v5.0 first working core using lomse |
1 |
//---------------------------------------------------------------------------------------
|
2 |
// LenMus Phonascus: The teacher of music
|
|
640
by cecilios
Fixed bug with tied notes in composer. Fixed memory leaks in FragmentsTable. Updates checker implemented.Language files reviewed. |
3 |
// Copyright (c) 2002-2012 LenMus project
|
624
by cecilios
Initial update for v5.0 first working core using lomse |
4 |
//
|
5 |
// This program is free software; you can redistribute it and/or modify it under the
|
|
6 |
// terms of the GNU General Public License as published by the Free Software Foundation,
|
|
7 |
// either version 3 of the License, or (at your option) any later version.
|
|
8 |
//
|
|
9 |
// This program is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
10 |
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
|
11 |
// PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
|
12 |
//
|
|
13 |
// You should have received a copy of the GNU General Public License along with this
|
|
14 |
// program. If not, see <http://www.gnu.org/licenses/>.
|
|
15 |
//
|
|
16 |
// For any comment, suggestion or feature request, please contact the manager of
|
|
17 |
// the project at cecilios@users.sourceforge.net
|
|
18 |
//
|
|
19 |
//---------------------------------------------------------------------------------------
|
|
632
by cecilios
colors, global flags, dlg choose language, splash |
20 |
|
21 |
#ifndef __LENMUS_PREFERENCES_H__
|
|
22 |
#define __LENMUS_PREFERENCES_H__
|
|
23 |
||
640
by cecilios
Fixed bug with tied notes in composer. Fixed memory leaks in FragmentsTable. Updates checker implemented.Language files reviewed. |
24 |
//#include "lenmus_standard_header.h"
|
632
by cecilios
colors, global flags, dlg choose language, splash |
25 |
//#include <vector>
|
26 |
//#include <wx/config.h>
|
|
27 |
//
|
|
28 |
//
|
|
29 |
//// the config object
|
|
633
by cecilios
last work before vacation |
30 |
//extern wxConfigBase *pPrefs;
|
632
by cecilios
colors, global flags, dlg choose language, splash |
31 |
//
|
32 |
////program: user options
|
|
33 |
//extern bool g_fAutoBeam;
|
|
34 |
//
|
|
35 |
//
|
|
36 |
//
|
|
37 |
//
|
|
38 |
////define data type to contain option info and value
|
|
39 |
//typedef struct lmOptionDataStruct
|
|
40 |
//{
|
|
41 |
// long id;
|
|
42 |
// long type; //long, float, bool, ...
|
|
43 |
// wxString sValue;
|
|
44 |
// long nValue;
|
|
45 |
// float rValue;
|
|
46 |
// bool fValue;
|
|
47 |
// wxString sGroup;
|
|
48 |
// wxString sSubgroup;
|
|
49 |
// wxString sName;
|
|
50 |
//
|
|
51 |
//} lmOptionData;
|
|
52 |
//
|
|
53 |
////to define type of units
|
|
54 |
//enum {
|
|
55 |
// lmOP_TENTHS = 0, //tenths
|
|
56 |
// lmOP_ENUM, //enumeration
|
|
57 |
// lmOP_BOOL, //boolean
|
|
58 |
//};
|
|
59 |
//
|
|
60 |
////Add a value for each option. Must be consecutive, and are used as indexes to access a vector.
|
|
61 |
//enum lmOptionId
|
|
62 |
//{
|
|
63 |
// //Engraving options
|
|
64 |
// //------------------------------------------------------
|
|
65 |
// lm_EO_FIRST_ENGRAVING = 0, //marker
|
|
66 |
// lm_EO_GRP_SPACE_AFTER_NAME,
|
|
67 |
// lm_EO_GRP_BRACKET_WIDTH,
|
|
68 |
// lm_EO_GRP_BRACKET_GAP,
|
|
69 |
// lm_EO_GRP_BRACE_WIDTH,
|
|
70 |
// lm_EO_GRP_BRACE_GAP,
|
|
71 |
// //Beams
|
|
72 |
// lm_EO_BEAM_THICKNESS,
|
|
73 |
// lm_EO_BEAM_SPACING,
|
|
74 |
// //
|
|
75 |
// lm_EO_LAST_ENGRAVING,
|
|
76 |
//
|
|
77 |
// //Edit options
|
|
78 |
// //------------------------------------------------------
|
|
79 |
// lm_DO_FIRST_EDIT = lm_EO_LAST_ENGRAVING, //marker
|
|
80 |
// //
|
|
81 |
// lm_DO_CLEF_CHANGE, //what to do when clef changed?: 0=ask, 1=keep pitch, 2=keep position
|
|
82 |
// lm_DO_KS_CHANGE, //what to do when key changed?: 0=ask, 1=keep pitch, 2=add accidentals
|
|
83 |
// lm_DO_AUTOBAR, //AutoBar: automatically insert a barline when a measure is full
|
|
84 |
// //
|
|
85 |
// lm_DO_LAST_EDIT,
|
|
86 |
//
|
|
87 |
// //End of lit
|
|
88 |
// lm_OP_END
|
|
89 |
//};
|
|
90 |
//
|
|
91 |
//
|
|
92 |
//
|
|
93 |
////--------------------------------------------------------------------------------------------
|
|
94 |
//// Program options
|
|
95 |
////--------------------------------------------------------------------------------------------
|
|
96 |
//
|
|
97 |
//class lmPgmOptions
|
|
98 |
//{
|
|
99 |
//public:
|
|
100 |
// ~lmPgmOptions();
|
|
101 |
//
|
|
102 |
// static lmPgmOptions* GetInstance();
|
|
103 |
// static void DeleteInstance();
|
|
104 |
//
|
|
105 |
// //creation / load / save
|
|
106 |
// void LoadDefaultValues();
|
|
107 |
//
|
|
108 |
// //access
|
|
109 |
// inline float GetFloatValue(lmOptionId nId) { return m_OptData[nId]->rValue; }
|
|
110 |
// inline long GetLongValue(lmOptionId nId) { return m_OptData[nId]->nValue; }
|
|
111 |
// inline wxString GetStringValue(lmOptionId nId) { return m_OptData[nId]->sValue; }
|
|
112 |
// inline bool GetBoolValue(lmOptionId nId) { return m_OptData[nId]->fValue; }
|
|
113 |
//
|
|
114 |
//
|
|
115 |
//protected:
|
|
116 |
// lmPgmOptions();
|
|
117 |
//
|
|
118 |
//private:
|
|
119 |
// void Register(lmOptionId nId, long nUnits, float rValue, wxString sKey);
|
|
120 |
// void Register(lmOptionId nId, long nUnits, long nValue, wxString sKey);
|
|
121 |
// void Register(lmOptionId nId, long nUnits, wxString sValue, wxString sKey);
|
|
122 |
// void Register(lmOptionId nId, long nUnits, bool fValue, wxString sKey);
|
|
123 |
//
|
|
124 |
// static lmPgmOptions* m_pInstance; //the only instance of this class
|
|
125 |
//
|
|
126 |
// std::vector<lmOptionData*> m_OptData;
|
|
127 |
//
|
|
128 |
//};
|
|
129 |
||
130 |
||
131 |
#endif // __LENMUS_PREFERENCES_H__ |
|
132 |