digiKam
Loading...
Searching...
No Matches
dcolorselector.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-02-20
7 * Description : color selector widget
8 *
9 * SPDX-FileCopyrightText: 2010-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
10 *
11 * SPDX-License-Identifier: GPL-2.0-or-later
12 *
13 * ============================================================ */
14
15#pragma once
16
17// Qt includes
18
19#include <QColor>
20#include <QPushButton>
21
22// Local includes
23
24#include "digikam_export.h"
25
26namespace Digikam
27{
28
32class DIGIKAM_EXPORT DColorSelector : public QPushButton
33{
34 Q_OBJECT
35
36public:
37
38 explicit DColorSelector(QWidget* const parent = nullptr);
39 ~DColorSelector() override;
40
41 void setColor(const QColor& color);
42 QColor color() const;
43
44 void setAlphaChannelEnabled(bool);
45
46Q_SIGNALS:
47
48 void signalColorSelected(const QColor&);
49
50private Q_SLOTS:
51
52 void slotBtnClicked();
53
54private:
55
56 void paintEvent(QPaintEvent*) override;
57
58private:
59
60 class Private;
61 Private* const d = nullptr;
62};
63
64} // namespace Digikam
Definition dcolorselector.h:33
void signalColorSelected(const QColor &)
Definition datefolderview.cpp:34