src/widgets/colorbutton.h

Sun, 02 Feb 2020 00:30:48 +0200

author
Teemu Piippo <teemu@hecknology.net>
date
Sun, 02 Feb 2020 00:30:48 +0200
changeset 41
0abada2a9802
parent 39
caac957e9834
permissions
-rw-r--r--

added automated configuration collection

#pragma once
#include <QPushButton>

/**
 * @brief A button that can be used to select a color
 */
class ColorButton : public QPushButton
{
public:
	ColorButton(const QColor& color = {}, QWidget* parent = nullptr);
	ColorButton(QWidget* parent = nullptr);
	QColor selectedColor() const;
	void setSelectedColor(const QColor& newSelectedColor);
private:
	QColor storedSelectedColor;
};

mercurial