40 #ifndef __OPENFLUID_UICOMMON_PREFERENCESDIALOG_HPP__ 41 #define __OPENFLUID_UICOMMON_PREFERENCESDIALOG_HPP__ 45 #include <QToolButton> 53 class PreferencesDialog;
57 class QTreeWidgetItem;
58 class WaresSearchPathsWidget;
61 namespace openfluid {
namespace ui {
namespace common {
78 enum PagesIndexes { ENVIRONMENT_PAGE = 0,
88 void changePage(QTreeWidgetItem* Current, QTreeWidgetItem* Previous);
90 void updateLanguage(
int Index);
92 void clearRecentsList();
94 void updateRecentsMax(
int Val);
96 void confirmItemRemoval(
bool Confirm);
98 void confirmParamRemoval(
bool Confirm);
100 void confirmUnitsRemoval(
bool Confirm);
102 void confirmConnectionsRemoval(
bool Confirm);
104 void confirmAttributesRemoval(
bool Confirm);
106 void enableWatchers(
bool Active);
108 void enableAutoSaveBeforeRun(
bool AutoSave);
110 void updateDeltaT(
int Val);
112 void updatePeriodBegin(
const QDateTime& DT);
114 void updatePeriodEnd(
const QDateTime& DT);
116 void enableSyntaxHighlighting(
bool Enable);
118 void changeSyntaxElementDecoration(
int ElementRow);
120 void enableCurrentLineHighlighting(
bool Enable);
122 void changeCurrentLineColor();
124 void changeCurrentFont(
const QFont& Font);
126 void enableLineWrapping(
bool Enable);
128 void changeIndentSpaceNumber(
int SpaceNb);
130 void changeSyntaxElementColor(
int ElementRow);
132 void addMarketPlace();
134 void editMarketPlace();
136 void removeMarketPlace();
138 void processSimUserPathsUpdate();
140 void processObsUserPathsUpdate();
142 void processBextUserPathsUpdate();
144 void processWorkspacesPathsUpdate();
146 void enableAutosaveBeforeBuild(
bool Enabled);
148 void updateDevConfigPATH();
150 void updateDevConfigGenerator();
152 void updateDevConfigOptions();
154 void updateDevBuildPATH();
156 void updateDevShowPATH(
bool Enabled);
158 void updateDevSslNoVerify(
bool NoVerify);
160 void detectQtDevToolsMinGW();
162 void applyTextEditorSettings();
164 void restoreDefaultsTextEditorSettings();
169 Ui::PreferencesDialog *ui;
171 bool m_RecentsChanged;
173 bool m_SimPathsChanged;
175 bool m_ObsPathsChanged;
177 bool m_WaresWatchingChanged;
179 bool m_TextEditorSettingsChanged;
181 bool m_RestartRequired;
183 int m_OriginalLangIndex;
185 QString m_OriginalActiveWorkspace;
189 QStringList m_Formats {
"bold",
"italic",
"underline",
"strike-through"};
193 void updateMarketplacesList();
195 void intializeTextEditorSettings();
197 void updateSyntaxElementLabel(QLabel* Label,
const QStringList& Decorations,
const QString& ColorName);
199 void updateSyntaxElementColorButton(QToolButton* Button,
const QString& ColorName);
201 void updateRestartStatus();
203 static QString getLanguageAsPrettyString(
const QString& LangCode);
208 void applyTextEditorSettingsAsked();
218 {
return m_RecentsChanged; }
221 {
return m_SimPathsChanged; }
224 {
return m_ObsPathsChanged; }
227 {
return m_WaresWatchingChanged; }
230 {
return m_TextEditorSettingsChanged; }
233 {
return m_RestartRequired; }
bool isObsPathsChanged() const
Definition: PreferencesDialog.hpp:223
Definition: PreferencesDialog.hpp:71
bool isRestartRequired()
Definition: PreferencesDialog.hpp:232
bool isWaresWatchingChanged() const
Definition: PreferencesDialog.hpp:226
Definition: MessageDialog.hpp:55
Definition: PreferencesDialog.hpp:64
Definition: ApplicationException.hpp:47
bool isTextEditorSettingsChanged() const
Definition: PreferencesDialog.hpp:229
#define OPENFLUID_API
Definition: dllexport.hpp:86
Definition: PreferencesDialog.hpp:70
bool isSimPathsChanged() const
Definition: PreferencesDialog.hpp:220
bool isRecentsChanged() const
Definition: PreferencesDialog.hpp:217
Definition: AboutDialog.hpp:50
DisplayMode
Definition: PreferencesDialog.hpp:70