Stretch Property

Measurement Studio User Interface

Stretch Property

Syntax

CWImage.Stretch

Data Type

Boolean

Purpose

Specifies if the image is displayed normal size or stretched to fit the size available within the control.

Remarks

This property only affects only bitmap and icon images. Metafile images stretch by default.

When Stretch is set to True, the image stretches to fit the bounding rectangle. If the bounding rectangle is smaller than the image, the image shrinks to the bounding rectangle regardless of the value of Stretch. If Stretch is set to False, the image continues to expand with the bounding rectangle until the bounding rectangle is larger than the image. If you use large images, consider resizing your image with a graphics application.

The Tile property takes precedence over the Stretch property. Thus, the Stretch property applies only when Tile is set to False.

This property does not apply to CWImage objects representing captions.

Example

'Turn stretching off for the CWButton's OffImage
CWButton1.OffImage.CWImage.Stretch = False

See Also

Tile