The 2D Scaling effect feature allows users to resize widgets and their layers, enabling adjustments to their dimensions along the x and y. The x and y axes correspond to the width and height of the image, respectively.
Types of Scaling
Upscaling: When the scaling factor is greater than 1000, the widget size is increased. For example, a scaling factor of 2000 results in the widget being twice its original size.
Note: A scaling factor of 1000 represents 100% of the widget’s original size.
Downscaling: When the scaling factor is less than 1000, the widget size is reduced. For instance, a scaling factor of 500 shrinks the widget to half its original size.
This effect is achieved by the following steps:
Drag and drop the desired widget into the design view.
In the “Effects” tab, apply a scaling effect to the desired widget. Note that in Flint, only the image layer of the widget can be scaled.
Input the scaling factor to x and y. To change the scale at runtime, map data variables to the required axis. In simulation, set the scaling factor to the respective axis.
Download the sample projects for the 2D Scale effect from the link provided below.
Points to be considered:
The Scaling effect is specifically intended for image layers and might only impact the image layer even if applied to widget.
Data storage should be set to INTU32.
Neither invalid nor empty data is permissible.