File indexing completed on 2025-01-05 04:54:20

0001 /*
0002    SPDX-FileCopyrightText: 2013-2024 Laurent Montel <montel@kde.org>
0003 
0004    SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 #pragma once
0007 #include "knotes_export.h"
0008 #include <Akonadi/Item>
0009 #include <QDialog>
0010 class QTabWidget;
0011 class KNoteEditorConfigWidget;
0012 class KNoteDisplayConfigWidget;
0013 class KNOTES_EXPORT KNoteSimpleConfigDialog : public QDialog
0014 {
0015     Q_OBJECT
0016 public:
0017     explicit KNoteSimpleConfigDialog(const QString &title, QWidget *parent = nullptr);
0018     ~KNoteSimpleConfigDialog() override;
0019 
0020     void load(Akonadi::Item &item, bool isRichText);
0021     void save(Akonadi::Item &item, bool &isRichText);
0022 
0023 public Q_SLOTS:
0024     void slotUpdateCaption(const QString &name);
0025 
0026 private:
0027     void readConfig();
0028     void writeConfig();
0029     QTabWidget *const mTabWidget;
0030     KNoteEditorConfigWidget *const mEditorConfigWidget;
0031     KNoteDisplayConfigWidget *const mDisplayConfigWidget;
0032 };