Note: ◼You may want to call RestoreAspectRatio before enabling AspectRatioLocked if you want to lock to the best AR for this layer ◼Dragging grips other than the corner will still allow users to skew the image. To avoid this use ShiftKeyLock ◼For polyline and shape layers, you can also maintain the aspect ratio when rotating by adding loResizeOnRotate to LayerOptions ◼AspectRatioLocked has no effect with line layers
Default: False (Except for TIEAngleLayer, where default is true)
// Lock layer to the current aspect ratio ImageEnView1.CurrentLayer.AspectRatioLocked := True;
// Force aspect ratio locking if the object prefers it if ImageEnView1.CurrentLayer.PreferredAspectRatio <> 0 then begin ImageEnView1.CurrentLayer.RestoreAspectRatio( True); ImageEnView1.CurrentLayer.AspectRatioLocked := True; ImageEnView1.Update(); end;