Graphics.ScaleX

From Xojo Documentation

Property (As Double )
aGraphics.ScaleX = newDoubleValue
or
DoubleValue = aGraphics.ScaleX

New in 2016r1

Supported for all project types and targets.

The scale factor used when converting user space coordinates to backing store coordinates. These can be modified at runtime and must be greater than zero.

Notes

When the Graphics object starts out, the scale is set to the the current transform used to convert user space coordinates to backing store coordinates. For example, the graphics object on a Canvas passed to a paint event might have the ScaleX and ScaleY set to 2 when drawing to a retina screen. For a bitmap Picture, the ScaleX and ScaleY properties are always 1.

The scale properties are not automatically updated if a control's backing store scale factor changes. They are, however, automatically updated when calling Graphics.NextPage in order to reset back to the state the printing system desires for that page.

Altering these properties will alter the object's height and width. Specifying a higher scale value will result in a lower size and vice versa. When a new graphics object is created as the result of calling Clip, the resulting object has the same scale factor as the original. Subsequent modifications to the scale on one object has no bearing on the other, however.