Shapes
This page covers IShape, IRectangle, ILinearShape, and IAnyShape. These interfaces appear inside pieces, stock, solution waste, and geometry-heavy export workflows.
The four IRectangle sides are signed Integer values. When the rectangle represents a minimum edge distance, a negative side means inherited or unspecified; consumers must not reinterpret it as an unsigned length.
Interfaces
IShape
Abstract shape contract used for non-rectangular pieces and waste geometry.
Source: SDK/include/pascal/uIShape.pas
Properties
- Property name
- ShapeType
- Type
- Description
Enumerated shape kind exposed by the current shape object.
Declaration
property ShapeType: TShapeType read GetShapeType;Published SDK declaration languages: Pascal.
- Property name
- EdgeCount
- Type
- Integer
- Description
Count of edge.
Declaration
property EdgeCount: Integer read GetEdgeCount;Published SDK declaration languages: Pascal.
- Property name
- ParamCount
- Type
- Integer
- Description
Count of param.
Declaration
property ParamCount: Integer read GetParamCount;Published SDK declaration languages: Pascal.
- Property name
- OnChange
- Type
- INotifyEvent
- Description
Event fired when the object or collection changes.
Declaration
property OnChange: INotifyEvent read GetOnChange;Published SDK declaration languages: Pascal.
Methods
- Method name
- SaveToString()
- Type
- WideString
- Description
Serialize the shape into a string representation.
Declaration
function SaveToString(aLengthUnit: TLengthUnits = luMillimeters; aAngleUnit: TAngleUnits = auRadians): WideString; safecall;Published SDK declaration languages: Pascal.
ParametersaLengthUnitValue for length unit.aAngleUnitValue for angle unit.ReturnsThe current shape serialized as a string.
- Method name
- LoadFromString()
- Type
- Boolean
- Description
Load the shape from a serialized string representation.
Declaration
function LoadFromString(const aString: WideString; aDefLengthUnit: TLengthUnits = luMillimeters; aDefAngleUnit: TAngleUnits = auRadians): Boolean; safecall;Published SDK declaration languages: Pascal.
ParametersaStringconstWideStringText value for string.aDefLengthUnitValue for def length unit.aDefAngleUnitValue for def angle unit.ReturnsReturnstrueif the serialized shape was parsed successfully.
- Method name
- GetNetPath()
- Type
- WideString
- Description
Return an SVG-compatible path representation of the shape using the requested dimensional context.
Declaration
function GetNetPath(aNetLength: Integer; aNetWidth: Integer; aSurplus: Integer; aMargin: Integer): WideString; safecall;Published SDK declaration languages: Pascal.
ParametersaNetLengthIntegerValue for net length.aNetWidthIntegerValue for net width.aSurplusIntegerSurplus value in TonCut units.aMarginIntegerMargin value in TonCut units.ReturnsThe SVG-compatible path string for the net shape outline.
- Method name
- GetGrossPath()
- Type
- WideString
- Description
Return an SVG-compatible path representation of the shape using the requested dimensional context.
Declaration
function GetGrossPath(aNetLength: Integer; aNetWidth: Integer; aSurplus: Integer; aMargin: Integer): WideString; safecall;Published SDK declaration languages: Pascal.
ParametersaNetLengthIntegerValue for net length.aNetWidthIntegerValue for net width.aSurplusIntegerSurplus value in TonCut units.aMarginIntegerMargin value in TonCut units.ReturnsThe SVG-compatible path string for the gross shape outline.
- Method name
- GetEdgeInfo()
- Type
- Boolean
- Description
Return metadata for a named or indexed shape edge.
Declaration
function GetEdgeInfo(aIndex: Integer; var aName: WideString; var aTitle: WideString): Boolean; safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.aNamevarWideStringText value for name. Passed by reference and may be updated by the callee.aTitlevarWideStringHuman-readable title. Passed by reference and may be updated by the callee.ReturnsReturnstrueif edge metadata was found for the requested index and the output parameters were populated.
- Method name
- GetEdgeBandByIndex()
- Type
- IBand
- Description
Return or populate edge band by index.
Declaration
function GetEdgeBandByIndex(aIndex: Integer): IBand; safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.ReturnsThe matching band interface instance.
- Method name
- SetEdgeBandByIndex()
- Type
- procedure
- Description
Assign edge band by index.
Declaration
procedure SetEdgeBandByIndex(aIndex: Integer; const aBand: IBand); safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.
- Method name
- GetEdgeBandByName()
- Type
- IBand
- Description
Return or populate edge band by name.
Declaration
function GetEdgeBandByName(const aName: WideString): IBand; safecall;Published SDK declaration languages: Pascal.
ParametersaNameconstWideStringText value for name.ReturnsThe matching band interface instance.
- Method name
- SetEdgeBandByName()
- Type
- procedure
- Description
Assign edge band by name.
Declaration
procedure SetEdgeBandByName(const aName: WideString; const aBand: IBand); safecall;Published SDK declaration languages: Pascal.
ParametersaNameconstWideStringText value for name.
- Method name
- GetParamInfo()
- Type
- Boolean
- Description
Return metadata for a named or indexed shape parameter.
Declaration
function GetParamInfo(aIndex: Integer; var aName: WideString; var aTitle: WideString; var aType: TShapeParamType): Boolean; safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.aNamevarWideStringText value for name. Passed by reference and may be updated by the callee.aTitlevarWideStringHuman-readable title. Passed by reference and may be updated by the callee.aTypevarExtension category being enumerated. Passed by reference and may be updated by the callee.ReturnsReturnstrueif parameter metadata was found for the requested index and the output parameters were populated.
- Method name
- GetParamByIndex()
- Type
- Integer
- Description
Return or populate param by index.
Declaration
function GetParamByIndex(aIndex: Integer): Integer; safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.ReturnsSigned integer value.
- Method name
- SetParamByIndex()
- Type
- procedure
- Description
Assign param by index.
Declaration
procedure SetParamByIndex(aIndex: Integer; aValue: Integer); safecall;Published SDK declaration languages: Pascal.
ParametersaIndexIntegerZero-based position within a collection.aValueIntegerValue being formatted, assigned, or stored.
- Method name
- GetParamByName()
- Type
- Integer
- Description
Return or populate param by name.
Declaration
function GetParamByName(const aName: WideString): Integer; safecall;Published SDK declaration languages: Pascal.
ParametersaNameconstWideStringText value for name.ReturnsSigned integer value.
- Method name
- SetParamByName()
- Type
- procedure
- Description
Assign param by name.
Declaration
procedure SetParamByName(const aName: WideString; aValue: Integer); safecall;Published SDK declaration languages: Pascal.
ParametersaNameconstWideStringText value for name.aValueIntegerValue being formatted, assigned, or stored.
- Method name
- IsSame()
- Type
- Boolean
- Description
Compare two shapes for structural equality.
Declaration
function IsSame(const aOther: IShape): Boolean; safecall;Published SDK declaration languages: Pascal.
ParametersReturnsReturnstrueif the supplied shape describes the same geometry as the current shape.
IRectangle
Signed four-side helper used for margins, edging, and edge-distance measurements. A negative side represents an inherited or unspecified edge distance.
Source: SDK/include/pascal/uIRectangle.pas
Properties
- Property name
- North
- Type
- Integer
- Description
Signed value assigned to the north or top edge; a negative edge-distance value means inherited or unspecified.
Declaration
property North: Integer read GetNorth write SetNorth;Published SDK declaration languages: Pascal.
- Property name
- South
- Type
- Integer
- Description
Signed value assigned to the south or bottom edge; a negative edge-distance value means inherited or unspecified.
Declaration
property South: Integer read GetSouth write SetSouth;Published SDK declaration languages: Pascal.
- Property name
- West
- Type
- Integer
- Description
Signed value assigned to the west or left edge; a negative edge-distance value means inherited or unspecified.
Declaration
property West: Integer read GetWest write SetWest;Published SDK declaration languages: Pascal.
- Property name
- East
- Type
- Integer
- Description
Signed value assigned to the east or right edge; a negative edge-distance value means inherited or unspecified.
Declaration
property East: Integer read GetEast write SetEast;Published SDK declaration languages: Pascal.
- Property name
- Top
- Type
- Integer
- Description
Alias of
North; a negative edge-distance value means inherited or unspecified.Declaration
property Top: Integer read GetNorth write SetNorth;Published SDK declaration languages: Pascal.
- Property name
- Bottom
- Type
- Integer
- Description
Alias of
South; a negative edge-distance value means inherited or unspecified.Declaration
property Bottom: Integer read GetSouth write SetSouth;Published SDK declaration languages: Pascal.
- Property name
- Left
- Type
- Integer
- Description
Alias of
West; a negative edge-distance value means inherited or unspecified.Declaration
property Left: Integer read GetWest write SetWest;Published SDK declaration languages: Pascal.
- Property name
- Right
- Type
- Integer
- Description
Alias of
East; a negative edge-distance value means inherited or unspecified.Declaration
property Right: Integer read GetEast write SetEast;Published SDK declaration languages: Pascal.
- Property name
- OnChange
- Type
- INotifyEvent
- Description
Event fired when the object or collection changes.
Declaration
property OnChange: INotifyEvent read GetOnChange;Published SDK declaration languages: Pascal.
Methods
- Method name
- Assign()
- Type
- procedure
- Description
Copy values from another object of the same type.
Declaration
procedure Assign(const aOther: IRectangle); safecall;Published SDK declaration languages: Pascal.
Parameters
- Method name
- BeginUpdate()
- Type
- procedure
- Description
Start a batched update so change notifications can be delayed.
Declaration
procedure BeginUpdate(); safecall;Published SDK declaration languages: Pascal.
- Method name
- EndUpdate()
- Type
- procedure
- Description
Finish a batched update and allow deferred notifications to resume.
Declaration
procedure EndUpdate(); safecall;Published SDK declaration languages: Pascal.
ILinearShape
Linear shape specialization that stores a sequence of segments.
Source: SDK/include/pascal/uILinearShape.pas
Properties
- Property name
- LeftAngle
- Type
- Double
- Description
Gets or sets left angle.
Declaration
property LeftAngle: Double read GetLeftAngle write SetLeftAngle;Published SDK declaration languages: Pascal.
- Property name
- RightAngle
- Type
- Double
- Description
Whether the shape or cut is a right angle.
Declaration
property RightAngle: Double read GetRightAngle write SetRightAngle;Published SDK declaration languages: Pascal.
IAnyShape
Arbitrary-path shape variant whose geometry is stored as a serialized path string.
Source: SDK/include/pascal/uIAnyShape.pas
Properties
- Property name
- Path
- Type
- WideString
- Description
SVG-compatible path content stored by the arbitrary-shape object.
Declaration
property Path: WideString read GetPath write SetPath;Published SDK declaration languages: Pascal.