#ifndef COLORACTION_H #define COLORACTION_H #include #include class ColorAction : public QAction { Q_OBJECT public: ColorAction(QObject *parent); const QColor& color() const { return m_color; } void setColor(const QColor &color); Q_SIGNALS: void colorChanged(const QColor &color); private Q_SLOTS: void chooseColor(); private: QColor m_color; }; #endif // COLORACTION_H