40 #ifndef __OPENFLUID_UICOMMON_PREFERENCESDIALOG_HPP__ 41 #define __OPENFLUID_UICOMMON_PREFERENCESDIALOG_HPP__ 47 #include <QToolButton> 52 class PreferencesDialog;
56 class QTreeWidgetItem;
57 class WaresSearchPathsWidget;
60 namespace openfluid {
namespace ui {
namespace common {
77 enum PagesIndexes { ENVIRONMENT_PAGE = 0,
87 void changePage(QTreeWidgetItem* Current, QTreeWidgetItem* Previous);
89 void updateLanguage(
int Index);
91 void clearRecentsList();
93 void updateRecentsMax(
int Val);
95 void confirmItemRemoval(
bool Confirm);
97 void confirmParamRemoval(
bool Confirm);
99 void confirmUnitsRemoval(
bool Confirm);
101 void confirmConnectionsRemoval(
bool Confirm);
103 void confirmAttributesRemoval(
bool Confirm);
105 void enableWatchers(
bool Active);
107 void enableAutoSaveBeforeRun(
bool AutoSave);
109 void updateDeltaT(
int Val);
111 void updatePeriodBegin(
const QDateTime& DT);
113 void updatePeriodEnd(
const QDateTime& DT);
115 void enableSyntaxHighlighting(
bool Enable);
117 void changeSyntaxElementDecoration(
int ElementRow);
119 void enableCurrentLineHighlighting(
bool Enable);
121 void changeCurrentLineColor();
123 void changeCurrentFont(
const QFont& Font);
125 void enableLineWrapping(
bool Enable);
127 void changeIndentSpaceNumber(
int SpaceNb);
129 void changeSyntaxElementColor(
int ElementRow);
131 void addMarketPlace();
133 void editMarketPlace();
135 void removeMarketPlace();
137 void processSimUserPathsUpdate();
139 void processObsUserPathsUpdate();
141 void processBextUserPathsUpdate();
143 void processWorkspacesPathsUpdate();
145 void updateDevConfigPATH();
147 void updateDevConfigGenerator();
149 void updateDevConfigOptions();
151 void updateDevBuildPATH();
153 void updateDevShowPATH(
bool Enabled);
155 void updateDevSslNoVerify(
bool NoVerify);
157 void detectQtDevToolsMinGW();
159 void applyTextEditorSettings();
161 void restoreDefaultsTextEditorSettings();
166 Ui::PreferencesDialog *ui;
168 bool m_RecentsChanged;
170 bool m_SimPathsChanged;
172 bool m_ObsPathsChanged;
174 bool m_WaresWatchingChanged;
176 bool m_TextEditorSettingsChanged;
178 bool m_RestartRequired;
180 int m_OriginalLangIndex;
182 QString m_OriginalActiveWorkspace;
186 QStringList m_Formats {
"bold",
"italic",
"underline",
"strike-through"};
190 void updateMarketplacesList();
192 void intializeTextEditorSettings();
194 void updateSyntaxElementLabel(QLabel* Label,
const QStringList& Decorations,
const QString& ColorName);
196 void updateSyntaxElementColorButton(QToolButton* Button,
const QString& ColorName);
198 void updateRestartStatus();
200 static QString getLanguageAsPrettyString(
const QString& LangCode);
205 void applyTextEditorSettingsAsked();
215 {
return m_RecentsChanged; }
218 {
return m_SimPathsChanged; }
221 {
return m_ObsPathsChanged; }
224 {
return m_WaresWatchingChanged; }
227 {
return m_TextEditorSettingsChanged; }
230 {
return m_RestartRequired; }
#define OPENFLUID_API
Definition: dllexport.hpp:87
bool isRestartRequired()
Definition: PreferencesDialog.hpp:229
Definition: ApplicationException.hpp:47
bool isWaresWatchingChanged() const
Definition: PreferencesDialog.hpp:223
bool isTextEditorSettingsChanged() const
Definition: PreferencesDialog.hpp:226
bool isObsPathsChanged() const
Definition: PreferencesDialog.hpp:220
DisplayMode
Definition: PreferencesDialog.hpp:69
Definition: PreferencesDialog.hpp:63
Definition: OpenFLUIDDialog.hpp:50
bool isSimPathsChanged() const
Definition: PreferencesDialog.hpp:217
Definition: AboutDialog.hpp:51
bool isRecentsChanged() const
Definition: PreferencesDialog.hpp:214
Definition: PreferencesDialog.hpp:69
Definition: PreferencesDialog.hpp:70