Merge pull request #7326 from spycrab/qt_tas_fancy

Qt/TAS: Enable antialiasing for Stick/IR widgets
This commit is contained in:
spycrab 2018-08-15 19:46:56 +02:00 committed by GitHub
commit 8e5c3d5b4e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 0 deletions

View File

@ -37,6 +37,9 @@ void IRWidget::paintEvent(QPaintEvent* event)
{
QPainter painter(this);
painter.setRenderHint(QPainter::Antialiasing, true);
painter.setRenderHint(QPainter::SmoothPixmapTransform, true);
painter.setBrush(Qt::white);
painter.drawRect(0, 0, width() - 1, height() - 1);

View File

@ -38,6 +38,9 @@ void StickWidget::paintEvent(QPaintEvent* event)
{
QPainter painter(this);
painter.setRenderHint(QPainter::Antialiasing, true);
painter.setRenderHint(QPainter::SmoothPixmapTransform, true);
painter.setBrush(Qt::white);
painter.drawEllipse(0, 0, width() - 1, height() - 1);