KConfigWidgets

kconfigviewstatesaver.h
1 
2 #ifndef KCONFIGVIEWSTATESAVER_H
3 #define KCONFIGVIEWSTATESAVER_H
4 
5 #include <KViewStateSerializer>
6 
7 #include "kconfigwidgets_export.h"
8 
9 class KConfigGroup;
10 
11 /**
12  * @class KConfigViewStateSaver kconfigviewstatesaver.h KConfigViewStateSaver
13  *
14  * @brief Base class for saving and restoring state in QTreeViews and QItemSelectionModels using KConfig as storage
15  */
16 class KCONFIGWIDGETS_EXPORT KConfigViewStateSaver : public KViewStateSerializer
17 {
18  Q_OBJECT
19 public:
20  explicit KConfigViewStateSaver(QObject *parent = nullptr);
21 
22  /**
23  Saves the state to the @p configGroup
24  */
25  void saveState(KConfigGroup &configGroup);
26 
27  /**
28  Restores the state from the @p configGroup
29  */
30  void restoreState(const KConfigGroup &configGroup);
31 };
32 
33 #endif
Base class for saving and restoring state in QTreeViews and QItemSelectionModels using KConfig as sto...
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Wed Jun 7 2023 03:50:22 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.