## 鼠標坐標位置的獲取
```python
import os
import time
import pyautogui as pag
''' 功能:獲取坐標'''
try:
while True:
print("Press Ctrl-C to end")
screenWidth, screenHeight = pag.size() #獲取屏幕的尺寸
print(screenWidth,screenHeight)
ptx,pty = pag.position() #獲取當前鼠標的位置
showStr = "Position:" + str(ptx).rjust(4)+','+str(pty).rjust(4)
print(showStr) ###
time.sleep(0.5)
os.system('cls') #清除屏幕
except KeyboardInterrupt:
print('end....')
```
## 鍵盤操作
### wright()
經過測試,pyautogui的wright()函數對中文的支持不好。