#ifndef PROMPTWIDGET_H
#define PROMPTWIDGET_H

#include <QWidget>
#include <QX11Info>
#include <QHBoxLayout>
#include <QLabel>

class PromptWidget : public QWidget
{
    Q_OBJECT

public:
    explicit PromptWidget(QWidget *parent = nullptr);
    void initUi();
    void initColor();
    void setColor(QColor c){m_color = c;}
    void setRadius(int radius){m_radius = radius; repaint();}

protected:
    bool nativeEvent(const QByteArray &eventType, void *message, long *result) Q_DECL_OVERRIDE;
    void paintEvent(QPaintEvent *event) Q_DECL_OVERRIDE;

private:
    int volunmPosX;
    int volunmPosY;
    int volunmPosWidth;
    int volunmPosHeight;
    int m_radius;
    QColor m_color;
    QHBoxLayout *HLayout = nullptr;
    QLabel *iconLabel = nullptr;
    QLabel *promptLabel = nullptr;
};

#endif // PROMPTWIDGET_H
