If we want to know the windows' screen resolution, we can use the win32api and win32con to get the value from windows.
The example as below.
import win32api, win32con
y = win32api.GetSystemMetrics(win32con.SM_CYSCREEN)
x = win32api.GetSystemMetrics(win32con.SM_CXSCREEN)
print(x, ",", y)
The execution result:
2560 , 1080
Process finished with exit code 0
沒有留言:
張貼留言