diff --git a/docs/introduction.rst b/docs/introduction.rst index 2d04505..d2dbfa6 100644 --- a/docs/introduction.rst +++ b/docs/introduction.rst @@ -33,7 +33,7 @@ Examples >>> pyautogui.click() >>> pyautogui.moveRel(None, 10) # move mouse 10 pixels down >>> pyautogui.doubleClick() - >>> pyautogui.moveTo(500, 500, duration=2, tween=pyautogui.tweens.easeInOutQuad) # use tweening/easing function to move mouse over 2 seconds. + >>> pyautogui.moveTo(500, 500, duration=2, tween=pyautogui.easeInOutQuad) # use tweening/easing function to move mouse over 2 seconds. >>> pyautogui.typewrite('Hello world!', interval=0.25) # type with quarter-second pause in between each key >>> pyautogui.press('esc') >>> pyautogui.keyDown('shift') diff --git a/docs/mouse.rst b/docs/mouse.rst index 144cdb1..2782c48 100644 --- a/docs/mouse.rst +++ b/docs/mouse.rst @@ -131,7 +131,7 @@ Tweening is an extra feature to make the mouse movements fancy. You can probably A tween or easing function dictates the progress of the mouse as it moves to its destination. Normally when moving the mouse over a duration of time, the mouse moves directly towards the destination in a straight line at a constant speed. This is known as a *linear tween* or *linear easing* function. -PyAutoGUI has other tweening functions available in the ``pyautogui.tweens`` module. The ``pyautogui.tweens.easeInQuad`` function can be passed for the 4th argument to ``moveTo()``, ``moveRel()``, ``dragTo()``, and ``dragRel()`` functions to have the mouse cursor start off moving slowly and then speeding up towards the destination. The total duration is still the same as the argument passed to the function. The ``pyautogui.tweens.easeOutQuad`` is the reverse: the mouse cursor starts moving fast but slows down as it approaches the destination. The ``pyautogui.tweens.easeOutElastic`` will overshoot the destination and "rubber band" back and forth until it settles at the destination. +PyAutoGUI has other tweening functions available in the ``pyautogui`` module. The ``pyautogui.easeInQuad`` function can be passed for the 4th argument to ``moveTo()``, ``moveRel()``, ``dragTo()``, and ``dragRel()`` functions to have the mouse cursor start off moving slowly and then speeding up towards the destination. The total duration is still the same as the argument passed to the function. The ``pyautogui.easeOutQuad`` is the reverse: the mouse cursor starts moving fast but slows down as it approaches the destination. The ``pyautogui.easeOutElastic`` will overshoot the destination and "rubber band" back and forth until it settles at the destination. For example: