|
@@ -1,3 +1,20 @@
|
|
# pyscreeze
|
|
# pyscreeze
|
|
|
|
|
|
-截屏工具
|
|
|
|
|
|
+截屏工具
|
|
|
|
+
|
|
|
|
+## Usage
|
|
|
|
+
|
|
|
|
+```
|
|
|
|
+import pyscreeze
|
|
|
|
+im1 = pyscreeze.screenshot()
|
|
|
|
+im2 = pyscreeze.screenshot('my_screenshot.png')
|
|
|
|
+
|
|
|
|
+```
|
|
|
|
+可以截图,找到指定按钮,模拟操作等
|
|
|
|
+
|
|
|
|
+如屏幕中按钮图片calc7key.png,通过locateOnScreen找到图片位置,返回左上角坐标和宽高
|
|
|
|
+```
|
|
|
|
+button7location = pyscreeze.locateOnScreen('calc7key.png')
|
|
|
|
+button7x, button7y = pyscreeze.center(button7location)
|
|
|
|
+
|
|
|
|
+```
|