#pragma once

#include <QLabel>

class Tag : public QLabel
{
	Q_OBJECT
public:
	Tag(QString text, QWidget *parent = nullptr);

protected:
	void mouseReleaseEvent(QMouseEvent *ev) override;
	void mouseMoveEvent(QMouseEvent *ev) override;
	void paintEvent(QPaintEvent *) override;

Q_SIGNALS:
	void removed(Tag*);

private:
	int textWidth;
};
