Skip to content

Commit c02851a

Browse files
committed
Fixes for python 3.10
Python 3.10 removed implicit conversions in some cases. This impacts PyQt functions. > Builtin and extension functions that take integer arguments no longer > accept Decimals, Fractions and other objects ... https://docs.python.org/3.10/whatsnew/3.10.html#other-language-changes
1 parent 723e733 commit c02851a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Display/SimpleGui.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,8 @@ def __init__(self, *args: Any) -> None:
179179
def centerOnScreen(self) -> None:
180180
"""Centers the window on the screen."""
181181
resolution = QtWidgets.QApplication.desktop().screenGeometry()
182-
x = (resolution.width() - self.frameSize().width()) / 2
183-
y = (resolution.height() - self.frameSize().height()) / 2
182+
x = (resolution.width() - self.frameSize().width()) // 2
183+
y = (resolution.height() - self.frameSize().height()) // 2
184184
self.move(x, y)
185185

186186
def add_menu(self, menu_name: str) -> None:

0 commit comments

Comments
 (0)