digiKam
curvessettings.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-01
7  * Description : Curves 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_CURVES_SETTINGS_H
25 #define DIGIKAM_CURVES_SETTINGS_H
26 
27 // Local includes
28 
29 #include <QWidget>
30 
31 // Local includes
32 
33 #include "digikam_export.h"
34 #include "curvesfilter.h"
35 #include "curveswidget.h"
36 #include "curvesbox.h"
37 #include "dimg.h"
38 
39 class KConfigGroup;
40 
41 namespace Digikam
42 {
43 
44 class DIGIKAM_EXPORT CurvesSettings : public QWidget
45 {
46  Q_OBJECT
47 
48 public:
49 
50  explicit CurvesSettings(QWidget* const parent, DImg* const img);
51  ~CurvesSettings() override;
52 
53  CurvesContainer defaultSettings() const;
54  void resetToDefault();
55 
56  CurvesContainer settings() const;
57  void setSettings(const CurvesContainer& settings);
58 
59  void readSettings(KConfigGroup& group);
60  void writeSettings(KConfigGroup& group);
61 
62  void loadSettings();
63  void saveAsSettings();
64 
65  void setScale(HistogramScale type);
66  void setCurrentChannel(ChannelType channel);
67 
68  int curvesLeftOffset() const;
69 
70 Q_SIGNALS:
71 
74  void signalChannelReset(int);
76 
77 public Q_SLOTS:
78 
79  void slotSpotColorChanged(const Digikam::DColor& color);
80 
81 private:
82 
83  class Private;
84  Private* const d;
85 };
86 
87 } // namespace Digikam
88 
89 #endif // DIGIKAM_CURVES_SETTINGS_H
Definition: curvescontainer.h:44
Definition: curvessettings.h:45
Definition: dcolor.h:43
Definition: dimg.h:62
Definition: datefolderview.cpp:43
ChannelType
Definition: digikam_globals.h:159
HistogramScale
Definition: digikam_globals.h:145