Skip to content

Commit

Permalink
Add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
liyuanhe211 committed Oct 10, 2022
1 parent e413e46 commit 09a1024
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 0 additions & 3 deletions Eyring_Eq.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@
if not Qt.QApplication.instance():
Application = Qt.QApplication(sys.argv)

# Sometimes, the scaling factor of PyQt is different from the Windows system scaling factor, reason unknown
# For example, on a 4K screen sets to 250% scaling on Windows, PyQt reads a default 300% scaling,
# causing everything to be too large

if platform.system() == 'Windows':
import ctypes
Expand Down
5 changes: 5 additions & 0 deletions Python_Lib/My_Lib_PyQt.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@


def set_Windows_scaling_factor_env_var():

# Sometimes, the scaling factor of PyQt is different from the Windows system scaling factor, reason unknown
# For example, on a 4K screen sets to 250% scaling on Windows, PyQt reads a default 300% scaling,
# causing everything to be too large, this function is to determine the ratio of the real DPI and the PyQt DPI

import platform
if platform.system() == 'Windows':
import ctypes
Expand Down

0 comments on commit 09a1024

Please sign in to comment.