mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-10 00:04:48 -07:00
Adjust fontsize up on highdpi displays (#3610)
This commit is contained in:
parent
abe4f5ca60
commit
477faafb84
3 changed files with 9 additions and 6 deletions
|
|
@ -77,14 +77,14 @@ void AbstractCardItem::transformPainter(QPainter *painter, const QSizeF &transla
|
|||
|
||||
QRectF totalBoundingRect = painter->combinedTransform().mapRect(boundingRect());
|
||||
|
||||
resetPainterTransform(painter);
|
||||
int scale = resetPainterTransform(painter);
|
||||
|
||||
painter->translate(totalBoundingRect.width() / 2, totalBoundingRect.height() / 2);
|
||||
painter->rotate(angle);
|
||||
painter->translate(-translatedSize.width() / 2, -translatedSize.height() / 2);
|
||||
|
||||
QFont f;
|
||||
f.setPixelSize(fontSize);
|
||||
f.setPixelSize(fontSize * scale);
|
||||
|
||||
painter->setFont(f);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue