2
1
Fork 0
mirror of https://github.com/yuzu-emu/yuzu.git synced 2024-07-04 23:31:19 +01:00

Merge pull request #1336 from lioncash/antialias

yuzu/util: Antialias game list compatibility pixmaps
This commit is contained in:
bunnei 2018-09-17 09:47:34 -04:00 committed by GitHub
commit 08af788a57
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -30,8 +30,9 @@ QPixmap CreateCirclePixmapFromColor(const QColor& color) {
QPixmap circle_pixmap(16, 16); QPixmap circle_pixmap(16, 16);
circle_pixmap.fill(Qt::transparent); circle_pixmap.fill(Qt::transparent);
QPainter painter(&circle_pixmap); QPainter painter(&circle_pixmap);
painter.setRenderHint(QPainter::Antialiasing);
painter.setPen(color); painter.setPen(color);
painter.setBrush(color); painter.setBrush(color);
painter.drawEllipse(0, 0, 15, 15); painter.drawEllipse({circle_pixmap.width() / 2.0, circle_pixmap.height() / 2.0}, 7.0, 7.0);
return circle_pixmap; return circle_pixmap;
} }