Skip to main content

Drawing a gesture

You draw a gesture by holding a draw button, moving the mouse, and letting go. Input.Observer holds back the press while you draw. When you let go, it either runs an action, or hands the press back to the window as if Input.Observer weren't there. A keyboard key can draw the same way: see The draw key.

Draw buttons​

The right button is the only draw button at first. You can add or remove buttons on the General page:

Input.ObserverSimpleAdvanced
AUTOMATION
Actions
Text expansion
Autocorrect
Snippets
Sandbox
App groups
Ignore groups
Gestures
SETUP
General
Appearance
Security
Help
About
General
Starting a gesture
Draw buttons
Mouse buttons that start gesture capture. Including the left button is unusual but valid, e.g. for pen or tablet input with no separate secondary button.
Left buttonRight buttonMiddle buttonSide button 1Side button 2
Ignored modifier keys
Holding any of these keys when you press a draw button or the draw key skips gesture capture for that press.
CtrlShiftAlt
  1. Open General and find the Starting a gesture card.
  2. In Draw buttons ①, select every button that should draw. Select a selected button again to turn it off.
  3. Apply your changes.

Rules:

  • Any of Left button, Right button, Middle button, Side button 1 and Side button 2 can draw, and several can draw at once. Each one starts its own gesture.
  • With no draw button selected, mouse gestures are off entirely. Hotkeys and text expansion keep working.
  • An action's gesture trigger can ask for one draw button, or accept Any draw button. A trigger that names a button you turned off here never matches. See The Actions page.
  • The left button is unusual. Every left-button drag of 5 pixels or more over a window where gestures work becomes a gesture, so selecting text, dragging files and moving windows stop working there. It is useful for pen and tablet input, which has no second button.
  • Swapped mouse buttons. When Windows has the primary and secondary buttons switched, the names follow Windows: Right button is the button that opens context menus, which is the physical left button.
  • Each draw button can draw its own trail style. See Gesture trails.

The draw key​

note

Advanced mode. The Draw key row is on the General page, in the Starting a gesture card.

The draw key is a keyboard key that works like a draw button: hold it, move the mouse, and let go. It helps on a touchpad, where holding a button while you move is awkward. It also helps in programs that use right-button drags themselves, such as CAD or 3D tools: turn off Draw buttons start gestures here for them (see App groups), and draw there with the key.

Input.ObserverSimpleAdvanced
AUTOMATION
Actions
Text expansion
Autocorrect
Snippets
Recorder
Sandbox
App groups
Ignore groups
Gestures
ENGINE
Global events
Exclusion zones
Scripts
Plugins
SETUP
General
Appearance
Profiles
Console
Security
Help
About
General
Starting a gesture
Draw key
A key that draws a gesture while you hold it, like a draw button: hold it, move the mouse, let go. For touchpads, and for programs that use button drags themselves.
Caps Lock
  1. Open General and find the Starting a gesture card.
  2. In Draw key ①, pick a key. None turns the draw key off.
  3. Apply your changes.

Rules:

  • The keys you can pick are Caps Lock, Scroll Lock, Pause, Insert, the Menu key and F13 to F24. Keys you type with, and Ctrl, Shift, Alt, Win and AltGr, can't be the draw key: holding one back would break every shortcut that uses it.
  • Everything on this page works the same way with the draw key: the press that starts a gesture, a click or a gesture, what is held back while you draw, and how a gesture ends. Where the page says "the press", it is the key's press.
  • A tap of the draw key, without moving the mouse, reaches the window as a normal key tap, so a tap of Caps Lock still turns Caps Lock on or off. The tap takes effect when you let go of the key.
  • Holding the key still for the cancel timeout gives the key press back to the window, and your release follows.
  • The window that counts is the top-level window under the pointer when you press the key.
  • The draw key draws the trail style chosen for all gestures (see Gesture trails).
  • An action's gesture trigger can ask for Draw key, or accept Any draw button, which includes it. See The Actions page.
  • A hotkey that uses the draw key runs only where the key doesn't start a gesture. The Actions page marks such a hotkey.
  • Over a Remote Desktop or virtual machine window, the remote program may take the key before Input.Observer sees it.
  • On a Japanese keyboard, the Caps Lock (英数) key pressed on its own goes to the input method, so it can't draw. Pick another key from the list.

When a press starts a gesture​

Pressing a draw button starts a gesture capture unless one of these is true. In each case the press goes to the window untouched, with no delay:

The press passes through when…Where it is set
Input.Observer is turned off, or paused while a window is focusedThe tray icon, App groups
A key in Ignored modifier keys ② is held (Ctrl unless you change it)Ignored modifier keys
The window is in an ignore groupIgnore groups
No app group, and no Global group, has gestures working for the windowScope and fallback rules
The window's app group has Draw buttons start gestures here off (draw buttons only, not the draw key)App groups
The press is inside an exclusion zoneExclusion zones
The previous gesture's trail is still being erased (the built-in trail only, for a split second)Gesture trails
A script asked to let the next gesture through (EngineDisableNextGesture)Builtins

The window that counts is the top-level window under the pointer at the moment you press. A gesture drawn from a text box inside a browser counts as drawn over the browser window. Moving onto another window while you draw changes nothing.

A click or a gesture​

A press is not a gesture until the pointer has moved far enough from where you pressed:

  • Minimum gesture movement is 5 pixels, measured in a straight line from the press point.
  • Released before that: it was a click. Input.Observer sends the press and the release to the window at the press point, so a right-click still opens the context menu.
  • Moved that far: it is a gesture from then on, even if you move back to the start point.
note

Advanced mode. Minimum gesture movement (0 to 200 pixels) is on the General page's Starting a gesture card. At 0, the slightest movement makes a gesture.

While you draw​

  • The trail appears once the stroke is a gesture. The classic line also waits until the stroke has moved 8 pixels from the start (Draw after moving). The trail is drawn over every monitor, so a stroke can cross from one monitor to another. See Gesture trails.
  • The hint names the action that would run if you let go now. It appears once the stroke has lasted 150 milliseconds or moved 24 pixels, follows every change, and disappears whenever the stroke so far matches nothing. What the hint shows is exactly what runs when you let go. See Hints and messages.
  • Keys and other buttons are held back. Until you let go, keystrokes, mouse wheel turns and other mouse buttons reach no window. Pressing Ctrl, Shift, Alt or Win, another mouse button, or turning the wheel counts as a modifier for the gesture (see Modifiers and timing); other keys are simply dropped. Releasing Ctrl, Shift, Alt or Win always reaches the window. The stop-all-actions hotkey still works.
  • The wheel can run actions. A wheel tick that fits a wheel trigger runs its action at once, and from then on the press is no gesture: no trail, no hint, and letting go gives no click back.
  • Another button can run actions. Before you have moved far enough to start a gesture, clicking another mouse button that fits a button chord trigger runs its action at once, with the same result for the press as a wheel trigger.
  • Keys held before you pressed. If you let go of such a key while drawing, its release is held back too. Release keys let go during a gesture (on by default, Advanced mode, General page, Fine-tuning card) sends that release once the gesture ends, so the window doesn't think the key is still down.

Ending a gesture​

What happensWhat the window under the pointer getsWhat runs
You let go before moving 5 pixelsThe click, at the press pointNothing
You let go after drawing, and the stroke matches an actionNothing: the press is used upThe action
You let go after drawing, and nothing matchesNothing: the press is used upThe Nothing matched global event, if you set one up
You turned the wheel and a wheel trigger ran, then let goNothing: the press is used upThe wheel trigger's action, once for each tick, while you held the button
You clicked another button and a button chord trigger ran, then let goNothing, for either button: the press is used upThe chord trigger's action, once for each click, while you held the button
You held another button, then let go before moving 5 pixels, and a button chord trigger fitsNothing for this button; the held button's own click is the window'sThe chord trigger's action
You hold still for the cancel timeoutThe press, at the press point, then the pointer at its current position; your own release followsNothing
The gesture reaches the maximum gesture durationThe press, if the button is still down and no wheel or chord trigger ranNothing

In every case where the capture was started, the Draw button released global event runs when you let go, if you set one up, except after a cancel timeout or the maximum duration. See Global events.

Cancel timeout​

The cancel timeout gives the press back to the window when you hold still:

  • Cancel timeout is 500 milliseconds by default (General, Ending a gesture). Turn it off to let a capture stay open until you let go. Its range is 0 to 10,000 milliseconds; at 0, every capture is cancelled as soon as it starts.
  • Any mouse movement, key press or wheel tick during the gesture restarts it, so it only counts time you spend holding still. Pausing that long in the middle of a stroke ends the gesture and hands the press back: the window then sees an ordinary drag with that button.
  • A cancelled gesture runs nothing.
  • Once a wheel trigger has run, the cancel timeout no longer applies to that press: you can hold still between wheel ticks for as long as you like (Wheel triggers). The same goes once a button chord trigger has run (Button chord triggers).
note

Advanced mode. Drawing extends the cancel timeout (on by default) is the switch behind the restart rule. Turned off, the whole gesture must be finished within the cancel timeout, counted from the press, even while you keep drawing. An app group can override the cancel timeout for its own windows with its Cancel timeout card (0 to 60,000 milliseconds); see App groups.

Maximum gesture duration (10,000 milliseconds by default, 0 for no limit) ends any gesture that is still open after that long, counted from the press, whatever you are doing. It exists for a release that never reaches Input.Observer, for example because you let go on the Ctrl+Alt+Del screen. After a wheel or button chord trigger has run, it ends the press without giving it back, and your release stays with Input.Observer too, so no context menu opens.

After a match​

When a stroke matches an action:

  1. Activate the window under the gesture (on by default, General, When a gesture matches) brings the window you pressed over to the front, so anything the action types goes there.
  2. The action runs, with any Before and After actions around it. See Before and after actions.

Settings on this page​

SettingPage and cardDefaultRange
Draw buttonsGeneral, Starting a gestureRight buttonAny combination, or none
Draw key (Advanced)General, Starting a gestureNoneNone, Caps Lock, Scroll Lock, Pause, Insert, Menu key, F13–F24
Ignored modifier keysGeneral, Starting a gestureCtrlCtrl, Shift, Alt
Minimum gesture movement (Advanced)General, Starting a gesture5 px0–200 px
Wheel modifier window (Advanced)General, Starting a gesture500 ms0–10,000 ms
Cancel timeoutGeneral, Ending a gesture500 msOff, or 0–10,000 ms
Drawing extends the cancel timeout (Advanced)General, Ending a gestureOn
Maximum gesture duration (Advanced)General, Ending a gesture10,000 ms0 (no limit)–600,000 ms
Activate the window under the gestureGeneral, When a gesture matchesOn
Release keys let go during a gesture (Advanced)General, Fine-tuningOn

Wheel modifier window is explained in Modifiers and timing.