digiKam
bordersettings.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2010-03-17
7  * Description : Border settings view.
8  *
9  * Copyright (C) 2010-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
10  *
11  * This program is free software; you can redistribute it
12  * and/or modify it under the terms of the GNU General
13  * Public License as published by the Free Software Foundation;
14  * either version 2, or (at your option)
15  * any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_BORDER_SETTINGS_H
25 #define DIGIKAM_BORDER_SETTINGS_H
26 
27 // Local includes
28 
29 #include <QWidget>
30 #include <QColor>
31 
32 // Local includes
33 
34 #include "digikam_export.h"
35 #include "borderfilter.h"
36 
37 class KConfigGroup;
38 
39 namespace Digikam
40 {
41 
42 class DIGIKAM_EXPORT BorderSettings : public QWidget
43 {
44  Q_OBJECT
45 
46 public:
47 
48  explicit BorderSettings(QWidget* const parent);
49  ~BorderSettings() override;
50 
51  BorderContainer defaultSettings() const;
52  void resetToDefault();
53 
54  BorderContainer settings() const;
55  void setSettings(const BorderContainer& settings);
56 
57  void readSettings(KConfigGroup& group);
58  void writeSettings(KConfigGroup& group);
59 
60 Q_SIGNALS:
61 
63 
64 private Q_SLOTS:
65 
66  void slotBorderTypeChanged(int borderType);
67  void slotPreserveAspectRatioToggled(bool);
68  void slotColorForegroundChanged(const QColor& color);
69  void slotColorBackgroundChanged(const QColor& color);
70 
71 private:
72 
73  void toggleBorderSlider(bool b);
74 
75 private:
76 
77  class Private;
78  Private* const d;
79 };
80 
81 } // namespace Digikam
82 
83 #endif // DIGIKAM_BORDER_SETTINGS_H
Definition: bordercontainer.h:43
Definition: bordersettings.h:43
Definition: datefolderview.cpp:43