System

Overview

The system class contains methods for getting OS standard file system icons, preferences, settings and information.

Ancestors

  1. None
 

Descendants

  1. None
 

See Also

  1. None

Methods

clickAt(x, y)
Description

Left clicks at the specified X, Y coordinates. This causes a real left click mouse event within the operating system at the specified coordinates and is not simulated.

Definition

system.clickAt(x, y)
Parameters
NameTypeDescription
x integer The amount of pixels from the left of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
y integer The amount of pixels from the top of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
clickAtControl(control)
Description

Left clicks at the center of the specified Tint Control. This causes a real left click event within the operating system and is not simulated.

Definition

system.clickAtControl(control)
Parameters
NameTypeDescription
control Control The control to left click at. The center of the control is calculated as the target click area.
getIconForFile(file)
Description

Returns an image (data uri base 64 encoded) for the icon used by the system shell.

Definition

system.getIconForFile(file)
Parameters
NameTypeDescription
file string The path to the file to return its icon used in the system shell.
keyAtControl(input)
Description

Sends a key down and key up event through the OS, note the currently focused application, window and control will receive this event (and may not be the running application).

Definition

system.keyAtControl(input)
Parameters
NameTypeDescription
input string The character to send as a key up and key down event. Note this must be one single character e.g., 'a', 'b', or 'A', or 'B'. For a carrage return use 'ENTER' or 'RETURN', for shift use 'SHIFT', etc.
rightClickAt(x, y)
Description

Right clicks at the specified control. This causes a real right-click mouse event within the operating system at the specified coordinates and is not simulated.

Definition

system.rightClickAt(x, y)
Parameters
NameTypeDescription
x integer The amount of pixels from the left of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
y integer The amount of pixels from the top of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
rightClickAtControl(control)
Description

The right click at control method can be used for testing. This causes a real right-click event within the operating system and is not simulated.

Definition

system.rightClickAtControl(control)
Parameters
NameTypeDescription
control Control The control to right click at. The center of the control is calculated as the target click area.
scrollAt(x, y, upOrDown)
Description

Sends a scroll event through the operating system at the specified X, Y coordinates, note this is not simulated.

Definition

system.scrollAt(x, y, upOrDown)
Parameters
NameTypeDescription
x integer The amount of pixels from the left of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
y integer The amount of pixels from the top of the virtual screen (e.g., all of the connected monitors normalized into a coordinate system).
upOrDown boolean The direction to scroll vertically up or down (true/false).
scrollAtControl(control, upOrDown)
Description

Scrolls a control vertically up or down based on the value of upOrDown.

Definition

system.scrollAtControl(control, upOrDown)
Parameters
NameTypeDescription
control Control The control to scroll.
upOrDown boolean The direction to scroll vertically up or down (true/false).
takeSnapshotOfActiveScreen()
Description

Takes a screenshot of the current active screen and returns it as a string that is a base64 encoded PNG image.

Definition

system.takeSnapshotOfActiveScreen()
Returns
TypeDescription
string A base 64 encoded PNG of the screenshot.
takeSnapshotOfControl(control)
Description

Takes a snapshot of a Tint Control and returns back a base 64 encoded string that represents a PNG image.

Definition

system.takeSnapshotOfControl(control)
Parameters
NameTypeDescription
control Control The Tint control to take a snapshot of.
Returns
TypeDescription
string A base 64 encoded PNG of the snapshot.
takeSnapshotOfCurrentWindow()
Description

Takes a screenshot of the current focused window in the running application.

Definition

system.takeSnapshotOfCurrentWindow()
Returns
TypeDescription
string A base 64 encoded PNG of the screenshot.
takeSnapshotOfTopWindow()
Description

Takes a screenshot of the current top (but not necessarily focused) window in the running application.

Definition

system.takeSnapshotOfTopWindow()
Returns
TypeDescription
string A base 64 encoded PNG of the screenshot.
takeSnapshotOfWindow(window)
Description

Takes a screenshot of the window passed in and returns a base 64 encoded string that represents a PNG image.

Definition

system.takeSnapshotOfWindow(window)
Parameters
NameTypeDescription
window Window The window object to take a snapshot of.
Returns
TypeDescription
string A base 64 encoded PNG of the screenshot.