Screenshot

Overview

The Screenshot component can, among many other things, be used to take screenshots of the current screen.

Properties

Allow Screenshots

[ Setter only ]
Type: Boolean

Determines if the user can take screenshots of the current screen.

  • True - The user can take screenshots of the current screen.
  • False - The user will see a "Screenshots blocked" notice when the they try to take a screenshot of the current screen.

Dim Amount

[ Getter + Setter ]
Type: Number

The amount by which the space behind the screenshot preview should be dimmed. 0.0 corresponds to no dimming of the background, and 1.0 will completely blacken the background.

File Name

[ Getter + Setter ]
Type: Text

The name by which the screenshot taken will be saved. You can also specify the full path of the image to store it in an external directory. The file name is "Screenshot.png" by default.

Use Large Notification

[ Getter + Setter ]
Type: Boolean

Determines the size of the notification that is sent to the user (if Show Notification is set to True) after the screenshot is taken.

  • True - A large notification is shown to the user with the notification title and a preview of the screenshot that was taken.
  • False - A small notification is shown to the user with only the notification title.

Show Notification Share Button

[ Getter + Setter ]
Type: Boolean

Determines if a Share button is to be included in the notification that is sent to the user (if Show Notification is set to True) after the screenshot is taken.

  • True - A Share button is included in the notification, clicking on which will bring up the system's Sharing menu.
  • False - No Share icon will be shown to the user.

Notification Share Title

[ Getter + Setter ]
Type: Text

The text of the Share button that is sent to the user if Show Notification Share Button is set to True.

share-preview

Share menu triggered after the Share button was clicked.

Notification Title

[ Getter + Setter ]
Type: Text

The title of the notification that is sent to the user (if Show Notification is set to True) after a screenshot has been taken.

Show Notification

[ Getter + Setter ]
Type: Boolean

Determines if the user should be sent a notification after a screenshot has been taken.

  • True - A notification is sent to the user.
  • False - No notification is sent to the user.

notification-preview

Small notification (top) and large notification (bottom).

Show Preview

[ Getter + Setter ]
Type: Boolean

Determines if the user should be shown a preview of the screenshot that was just taken.

  • True - A preview of the screenshot is shown to the user.
  • False - No preview of the screenshot is shown to the user.

screenshot-preview

Screenshot preview.

Are Permissions Granted

[ Getter | Blocks only ]
Type: Boolean

Determines if the app has been given permissions to read and write the device's external storage.

  • True - Read/write permissions have been granted.
  • False - Permissions have not been granted.

Is Read Permission Granted

[ Getter | Blocks only ]
Type: Boolean

Determines if the app has been given permissions to read from the device's external storage.

  • True - Read permissions have been granted.
  • False - Permissions have not been granted.

Is Write Permission Granted

[ Getter | Blocks only ]
Type: Boolean

Determines if the app has been given permissions to write to the device's external storage.

  • True - Write permissions have been granted.
  • False - Permissions have not been granted.

Methods

Take Screenshot

[ None ]

Takes a screenshot of the currently open screen.

Events

Got Screenshot

[ Text image ]

Triggers when the screenshot that was taken has been saved to the device's storage.

Params
image Text: The path to the screenshot that was just taken.