Skip to content
Member Filters
Show Inherited
Show Protected
Show abstract
GR32_Image🞂TCustomImage32🞂ScaleModeProperty

TCustomImage32.ScaleMode

Sizing and scaling mode for bitmap rendering.

Declaration ​

pascal
type
  TScaleMode = (smNormal, smStretch, smScale, smResize, smOptimal, smOptimalScaled);

property ScaleMode: TScaleMode read FScaleMode write SetScaleMode;

Description ​

ScaleMode controls how the bitmap is scaled, stretched, or resized within the image control.

ValueDescription
smNormalRenders the bitmap at its original unscaled dimensions (1:1 scale ratio).
smStretchStretches the bitmap to fill the entire client area of the control, ignoring aspect ratio.
smScaleScales the bitmap using explicit horizontal (ScaleX) and vertical (ScaleY) scaling factors.
smResizeAutomatically resizes the control to match the bitmap size.
smOptimalAutomatically scales the bitmap down to fit inside the control while maintaining aspect ratio if the bitmap is larger than the control, or renders unscaled if smaller.
smOptimalScaledFits the bitmap inside the control while maintaining aspect ratio, scaling both up or down as required.

See also ​