/[svn]/gigedit/trunk/src/gigedit/Settings.h
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/Settings.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2893 by schoenebeck, Fri Apr 29 14:19:53 2016 UTC revision 3637 by schoenebeck, Thu Oct 24 13:12:52 2019 UTC
# Line 1  Line 1 
1  /*  /*
2      Copyright (c) 2014-2016 Christian Schoenebeck      Copyright (c) 2014-2019 Christian Schoenebeck
3            
4      This file is part of "gigedit" and released under the terms of the      This file is part of "gigedit" and released under the terms of the
5      GNU General Public License version 2.      GNU General Public License version 2.
# Line 12  Line 12 
12  #include <glibmm/object.h>  #include <glibmm/object.h>
13  #include <glibmm/property.h>  #include <glibmm/property.h>
14  #include <vector>  #include <vector>
15    #include "global.h"
16    
17  /**  /**
18   * Reflects, saves and restores all settings for the gigedit application.   * Reflects, saves and restores all settings for the gigedit application.
# Line 39  public: Line 40  public:
40          GLOBAL,          GLOBAL,
41          MAIN_WINDOW,          MAIN_WINDOW,
42          SCRIPT_EDITOR,          SCRIPT_EDITOR,
43            DIMENSION_MANAGER,
44            SCRIPT_SLOTS,
45            COMBINE_INSTRUMENTS,
46            MIDI_RULES,
47            FILE_PROPS,
48            INSTR_PROPS,
49            SAMPLE_PROPS,
50            SAMPLE_REFS,
51            MACRO_EDITOR,
52            MACROS_SETUP,
53            MACROS,
54      };      };
55    
56      /**      /**
# Line 61  public: Line 73  public:
73                  sigc::bind(                  sigc::bind(
74                      sigc::bind(                      sigc::bind(
75                          sigc::bind(                          sigc::bind(
76                              sigc::mem_fun(m_settings, &Settings::onPropertyChanged),                              sigc::mem_fun(*m_settings, &Settings::onPropertyChanged),
77                              m_group                              m_group
78                          ),                          ),
79                          type                          type
# Line 81  public: Line 93  public:
93                  sigc::bind(                  sigc::bind(
94                      sigc::bind(                      sigc::bind(
95                          sigc::bind(                          sigc::bind(
96                              sigc::mem_fun(m_settings, &Settings::onPropertyChanged),                              sigc::mem_fun(*m_settings, &Settings::onPropertyChanged),
97                              m_group                              m_group
98                          ),                          ),
99                          type                          type
# Line 114  public: Line 126  public:
126      Property<bool> warnUserOnExtensions; ///< if enabled, the user shall he be warned if he is trying to use a gig format extension that will not work with Gigasampler/GigaStudio      Property<bool> warnUserOnExtensions; ///< if enabled, the user shall he be warned if he is trying to use a gig format extension that will not work with Gigasampler/GigaStudio
127      Property<bool> syncSamplerInstrumentSelection; ///< if enabled, the sampler's current instrument will automatically be switched whenever another instrument was selected in gigedit      Property<bool> syncSamplerInstrumentSelection; ///< if enabled, the sampler's current instrument will automatically be switched whenever another instrument was selected in gigedit
128      Property<bool> moveRootNoteWithRegionMoved; ///< if enabled, the root note(s) of regions are automatically moving when the user drags a region around at the virtual keyboard      Property<bool> moveRootNoteWithRegionMoved; ///< if enabled, the root note(s) of regions are automatically moving when the user drags a region around at the virtual keyboard
129        Property<bool> autoRestoreWindowDimension;
130        Property<bool> saveWithTemporaryFile; ///< If enabled and the user selects "Save" from the main menu, then the file is first saved as separate temporary file and after the save operation completed the temporary file is moved over the original file.
131        Property<bool> showTooltips; ///< Whether tooltips specifically intended for newbies should be displayed throughout the application (default: yes).
132    
133      // settings of "MainWindow" group      // settings of "MainWindow" group
134      Property<int> mainWindowX;      Property<int> mainWindowX;
# Line 126  public: Line 141  public:
141      Property<int> scriptEditorWindowY;      Property<int> scriptEditorWindowY;
142      Property<int> scriptEditorWindowW;      Property<int> scriptEditorWindowW;
143      Property<int> scriptEditorWindowH;      Property<int> scriptEditorWindowH;
144        Property<int> scriptEditorFontSize;
145    
146        // settings of "DimensionManager" group
147        Property<int> dimensionManagerWindowX;
148        Property<int> dimensionManagerWindowY;
149        Property<int> dimensionManagerWindowW;
150        Property<int> dimensionManagerWindowH;
151    
152        // settings of "ScriptSlots" group
153        Property<int> scriptSlotsWindowX;
154        Property<int> scriptSlotsWindowY;
155        Property<int> scriptSlotsWindowW;
156        Property<int> scriptSlotsWindowH;
157    
158        // settings of "CombineInstruments" group
159        Property<int> combineInstrumentsWindowX;
160        Property<int> combineInstrumentsWindowY;
161        Property<int> combineInstrumentsWindowW;
162        Property<int> combineInstrumentsWindowH;
163    
164        // settings of "MidiRules" group
165        Property<int> midiRulesWindowX;
166        Property<int> midiRulesWindowY;
167        Property<int> midiRulesWindowW;
168        Property<int> midiRulesWindowH;
169    
170        // settings of "FileProps" group
171        Property<int> filePropsWindowX;
172        Property<int> filePropsWindowY;
173        Property<int> filePropsWindowW;
174        Property<int> filePropsWindowH;
175    
176        // settings of "InstrProps" group
177        Property<int> instrPropsWindowX;
178        Property<int> instrPropsWindowY;
179        Property<int> instrPropsWindowW;
180        Property<int> instrPropsWindowH;
181    
182        // settings of "SampleProps" group
183        Property<int> samplePropsWindowX;
184        Property<int> samplePropsWindowY;
185        Property<int> samplePropsWindowW;
186        Property<int> samplePropsWindowH;
187    
188        // settings of "SampleRefs" group
189        Property<int> sampleRefsWindowX;
190        Property<int> sampleRefsWindowY;
191        Property<int> sampleRefsWindowW;
192        Property<int> sampleRefsWindowH;
193    
194        // settings of "MacroEditor" group
195        Property<int> macroEditorWindowX;
196        Property<int> macroEditorWindowY;
197        Property<int> macroEditorWindowW;
198        Property<int> macroEditorWindowH;
199    
200        // settings of "MacrosSetup" group
201        Property<int> macrosSetupWindowX;
202        Property<int> macrosSetupWindowY;
203        Property<int> macrosSetupWindowW;
204        Property<int> macrosSetupWindowH;
205    
206      static Settings* singleton();      static Settings* singleton();
207      Settings();      Settings();
208      void load();      void load();
209        void loadMacros(std::vector<Serialization::Archive>& macros);
210        void saveMacros(const std::vector<Serialization::Archive>& macros);
211    
212  protected:  protected:
213      void onPropertyChanged(Glib::PropertyBase* pProperty, RawValueType_t type, Group_t group);      void onPropertyChanged(Glib::PropertyBase* pProperty, RawValueType_t type, Group_t group);

Legend:
Removed from v.2893  
changed lines
  Added in v.3637

  ViewVC Help
Powered by ViewVC