Windows Convenience API

Note: The Windows Convenience API is only available in the Squish for Windows editions.

Note: The Squish documentation uses the term widget when referring to GUI objects. Windows developers may be more familiar with the terms control and container, both of which are covered by the term widget in the Squish documentation.

GestureBuilder class (Windows)

A sequence of touch interactions.

chooseFile (Windows)

Automates a native file selection dialog.

clickButton (Windows)

Clicks on a button.

clickItem (Windows)

Clicks on an named item in a view.

collapse (Windows)

Collapses a Tree Item or hides a Combo Box.

collapseItem

Collapses an item in a tree.

doubleClick (Windows)

Double-clicks on a widget.

doubleClickItem (Windows)

Double-clicks a named item in a view.

dragAndDrop (Windows)

Performs a drag and drop operation.

expand (Windows)

Expands a Tree Item, or drops-down a Combo Box.

expandItem

Expands an item in a tree.

focusedWindow

Returns a reference to the object with keyboard focus.

gesture (Windows)

Plays a gesture.

installEventHandler (Windows)

Installs a global event handler.

mouseClick (Windows)

Clicks the mouse on the specified widget.

mouseDrag (Windows)

Performs a mouse drag.

mousePress (Windows)

Presses (without releasing) a mouse button.

mouseRelease (Windows)

Releases the mouse button.

mouseWheel (Windows)

Performs a mouse wheel operation.

nativeObject property (Windows)

A reference to an object containing native properties and methods.

readGesture (Windows)

Returns a GestureBuilder object after opening a Gesture file.

setFocusedWindow

Gives keyboard focus to a widget.

setForegroundWindow

Tries to bring a window into the foreground.

setValue (Windows)

Sets the value of a spinbox, slider, or scrollbar.

type (Windows)

Types text into an editable widget.

Windows Convenience Function Parameters

For all of the Windows Convenience API functions that take an objectOrName argument, this argument can be a reference to an object or the name of an object—the object must be (or name) a native Windows object.

Some of the Windows Convenience API functions can take a modifierState argument which indicates which special keys are pressed at the time of a mouse click. And some of the functions can also take a mouseButton argument which indicates which mouse button was clicked.

The modifierState can be one or more of the following: Modifier.NoModifier, Modifier.Alt, Modifier.Control, Modifier.Shift. If more than one is used they must be OR-d together, for example, Modifier.Alt|Modifier.Shift. The form shown here works e.g., Modifier::Control, and for Tcl use the enum function, e.g., enum Modifier Control.

The mouseButton can be any one of: MouseButton.NoButton, MouseButton.Wheel, MouseButton.LeftButton, MouseButton.MiddleButton, MouseButton.RightButton. MouseButton.XButton1. MouseButton.XButton2.

The form shown above works for Python and JavaScript.

For Perl use this: MouseButton::LeftButton, etc.

For Ruby use this: MouseButton::LEFT_BUTTON, etc.

For Tcl use this: enum MouseButton LeftButton, etc.

© 2024 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners.
The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation.
Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.

Search Results