XPlor/app/preferenceeditor.h

82 lines
1.8 KiB
C
Raw Normal View History

2025-09-05 20:44:33 +00:00
#ifndef PREFERENCEEDITOR_H
#define PREFERENCEEDITOR_H
#include <QDialog>
#include <QListWidget>
#include <QStackedWidget>
#include <QCheckBox>
#include <QSpinBox>
#include <QComboBox>
#include <QLineEdit>
#include <QPushButton>
#include <QLabel>
2025-09-05 20:44:33 +00:00
class PreferenceEditor : public QDialog
{
Q_OBJECT
public:
explicit PreferenceEditor(QWidget *parent = nullptr);
~PreferenceEditor() = default;
2025-09-05 20:44:33 +00:00
private slots:
void onCategoryChanged();
void onApply();
void onAccept();
void onBrowseExportDir();
void onBrowseQuickBms();
void onResetSettings();
2025-09-05 20:44:33 +00:00
private:
void setupUi();
void createAppearancePage();
void createGeneralPage();
void createToolsPage();
void createDebugPage();
void createTreePage();
void createPreviewPage();
void loadSettings();
void saveSettings();
void applyStylesheet();
void updateThemePreview();
// UI Components
QListWidget *m_categoryList;
QStackedWidget *m_pageStack;
// Appearance Page
QComboBox *m_themeCombo;
QLabel *m_themePreview;
// General Page
QLineEdit *m_exportDirEdit;
QCheckBox *m_autoExportCheck;
// Tools Page
QLineEdit *m_quickBmsEdit;
QLabel *m_quickBmsStatus;
// Debug Page
QCheckBox *m_debugLoggingCheck;
QCheckBox *m_verboseParsingCheck;
QCheckBox *m_logToFileCheck;
// Tree Page
QCheckBox *m_showCountsCheck;
QCheckBox *m_collapseDefaultCheck;
QCheckBox *m_groupByExtCheck;
QCheckBox *m_naturalSortCheck;
// Preview Page
QCheckBox *m_audioAutoPlayCheck;
QCheckBox *m_imageShowGridCheck;
QCheckBox *m_imageAutoZoomCheck;
// View Page
QComboBox *m_fontFamilyCombo;
QSpinBox *m_fontSizeSpin;
QSpinBox *m_zoomSpin;
2025-09-05 20:44:33 +00:00
};
#endif // PREFERENCEEDITOR_H