aboutsummaryrefslogtreecommitdiff
path: root/src/aotextboxwidgets.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/aotextboxwidgets.h')
-rw-r--r--src/aotextboxwidgets.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/aotextboxwidgets.h b/src/aotextboxwidgets.h
new file mode 100644
index 00000000..fa7288f8
--- /dev/null
+++ b/src/aotextboxwidgets.h
@@ -0,0 +1,32 @@
+#pragma once
+
+#include <QAbstractTextDocumentLayout>
+#include <QDebug>
+#include <QLabel>
+#include <QPaintEvent>
+#include <QPainter>
+#include <QPainterPath>
+#include <QTextEdit>
+
+class AOChatboxLabel : public QLabel
+{
+ Q_OBJECT
+
+public:
+ AOChatboxLabel(QWidget *parent);
+
+ void setIsOutlined(bool outlined);
+ void setOutlineColor(QColor color);
+ void setOutlineWidth(int width);
+
+ void setTextColor(QColor color);
+
+protected:
+ void paintEvent(QPaintEvent *event);
+
+private:
+ bool m_outline = false;
+ QColor m_outline_color;
+ int m_outline_width = 1;
+ QColor m_text_color;
+};