chore: ensure splash width is int

This commit is contained in:
Travis Abendshien
2024-09-02 00:43:11 -07:00
parent 1e4883c577
commit 1c53f05e4f

View File

@@ -293,13 +293,15 @@ class QtDriver(QObject):
splash_pixmap = QPixmap(":/images/splash.png")
splash_pixmap.setDevicePixelRatio(self.main_window.devicePixelRatio())
splash_pixmap = splash_pixmap.scaledToWidth(
min(
(
QGuiApplication.primaryScreen().geometry().width()
* self.main_window.devicePixelRatio()
math.floor(
min(
(
QGuiApplication.primaryScreen().geometry().width()
* self.main_window.devicePixelRatio()
)
/ 4,
splash_pixmap.width(),
)
// 4,
splash_pixmap.width(),
),
Qt.TransformationMode.SmoothTransformation,
)