diff options
author | fieldOfView <aldo@fieldofview.com> | 2017-09-26 12:56:14 +0300 |
---|---|---|
committer | fieldOfView <aldo@fieldofview.com> | 2017-09-26 12:56:14 +0300 |
commit | 565ed4933b5b7fca8f3a9546aa11010e9c5394dd (patch) | |
tree | a40f20f4a40b8e8cf4858c2ce1a1567579712194 /cura | |
parent | 7394a0c6efed90807d41ab908cac93b620149393 (diff) |
Use pixels instead of points for text in splash-screen
The current splashscreen implementation uses DPI-independent pixel sizes for everything, but point sizes take the DPI into account. This caused too large text and misalignment in the splash screen on Hi DPI screens on Windows.
Diffstat (limited to 'cura')
-rw-r--r-- | cura/CuraSplashScreen.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/cura/CuraSplashScreen.py b/cura/CuraSplashScreen.py index eedf1e3d53..f340c01623 100644 --- a/cura/CuraSplashScreen.py +++ b/cura/CuraSplashScreen.py @@ -10,7 +10,6 @@ from PyQt5.QtWidgets import QSplashScreen from UM.Resources import Resources from UM.Application import Application - class CuraSplashScreen(QSplashScreen): def __init__(self): super().__init__() @@ -61,7 +60,7 @@ class CuraSplashScreen(QSplashScreen): # draw version text font = QFont() # Using system-default font here - font.setPointSize(28) + font.setPixelSize(37) painter.setFont(font) painter.drawText(220, 66, 330 * self._scale, 230 * self._scale, Qt.AlignLeft | Qt.AlignTop, version[0]) if len(version) > 1: @@ -81,7 +80,7 @@ class CuraSplashScreen(QSplashScreen): # draw message text if self._current_message: font = QFont() # Using system-default font here - font.setPointSize(10) + font.setPixelSize(13) pen = QPen() pen.setColor(QColor(255, 255, 255, 255)) painter.setPen(pen) @@ -107,5 +106,3 @@ class CuraSplashScreen(QSplashScreen): self._to_stop = True self._change_timer.stop() super().close() - - |