scaleSelectedElement method

void scaleSelectedElement({
  1. required double scaleX,
  2. required double scaleY,
  3. ArcGISPoint? origin,
})

Scales the selected element by the specified factors.

If the origin ArcGISPoint has a different SpatialReference than the associated ArcGISMapViewController, the point will be reprojected before the geometry is rotated, using the default transformation.

Positive scale factors greater than 1 increase the size of the GeometryEditor.geometry, and positive factors between 0 and 1 reduce the size of the geometry. Negative scale factors produce a geometry reflected across the axes of the origin point. Negative factors less than -1 both reflect and increase the size of the geometry, and negative factors between -1 and 0 both reflect and reduce the size of the geometry.

Parameters:

  • scaleX — The scale factor along the x-axis. It can be positive or negative. It cannot be 0, or a non-numeric value.
  • scaleY — The scale factor along the y-axis. It can be positive or negative. It cannot be 0, or a non-numeric value.
  • origin — The point relative to which the geometry will be scaled. If null, or Geometry.isEmpty is true, the center of the extent of the GeometryEditor.selectedElement is used.

Implementation

void scaleSelectedElement({
  required double scaleX,
  required double scaleY,
  ArcGISPoint? origin,
}) {
  _withThrowingErrorHandler((errorHandler) {
    runtimecore.RT_GeometryEditor_scaleSelectedElement(
      _handle,
      scaleX,
      scaleY,
      origin?._handle ?? ffi.nullptr,
      errorHandler,
    );
  });
}