mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
21 lines
412 B
C++
21 lines
412 B
C++
#include "QWidget"
|
|
#include "QPainter"
|
|
#include "notebookpage.h"
|
|
#include "notebooktab.h"
|
|
|
|
NotebookPage::NotebookPage(NotebookTab *tab)
|
|
{
|
|
this->tab = tab;
|
|
tab->page = this;
|
|
}
|
|
|
|
void NotebookPage::paintEvent(QPaintEvent *)
|
|
{
|
|
QPainter painter(this);
|
|
|
|
painter.setPen(QColor(255, 0, 0));
|
|
painter.drawRect(0, 0, width() - 1, height() - 1);
|
|
|
|
painter.drawText(8, 8, QString::number(tab->x()));
|
|
}
|