Click or drag to resize

GeometryShapeGeometry Property

Gets or sets the shape's geometry that contains additional information about the ShapeType.

Namespace:  GemBox.Presentation
Assembly:  GemBox.Presentation (in GemBox.Presentation.dll) Version: 21.3.35.1041 (21.3.35.1041)
Syntax
public ShapeGeometry Geometry { get; set; }

Property Value

Type: ShapeGeometry
The shape's geometry that contains additional information about the ShapeType.
Exceptions
ExceptionCondition
ArgumentExceptionValue is a connector geometry and the current shape is not a Connector or value is not a connector geometry and the current shape is a Connector.
Remarks

This property always returns a new instance of a ShapeGeometry that points to geometry data associated with this shape. This reduces memory footprint since simpler internal structures can be used to hold the geometry data and execution time increase is negligible since Garbage Collector has a very good performance for a short-lived (Generation 0) objects. Also, this behavior is required because geometry can be inherited from the placeholder (and changes in the placeholder's geometry must be immediately visible in this shape's geometry), but when the geometry is being modified, it should be modified for this shape, not for the placeholder.

When setting a value, instance of a ShapeGeometry won't actually be stored in this shape, but the geometry data to which the instance points to will be copied. This enables easy copying of complex geometries from one shape to another.

See Also