Development version.
Forge is under active development and testing. APIs, behaviour, coverage and
verification results may be incomplete or change without notice; published
PASS results are not a support guarantee or production-readiness claim.
Shape.rectangular_pattern
Pattern an existing native history feature in one or two directions.
Signature
Shape.rectangular_pattern(self, feature, *, count, spacing, direction=<Axis.X: 'X'>, count2=None, spacing2=None, direction2=<Axis.Y: 'Y'>, alignment='right', alignment2='right', reversed=False, reversed2=False)Use when
Repeat an already-created native feature while keeping one editable SolidCraft rectangular-pattern history feature.
Limits
The source feature must already be part of this Shape. Supplying a second direction requires both count2 and spacing2.
Parameters
feature— Existing applied feature Shape, or a non-empty sequence of applied feature Shapes. Forge resolves each source to its native history feature.count— Number of instances in the first direction. Use a positive integer or direct Parameter.spacing— Instance spacing in the first direction, in mm.direction— First pattern direction as Axis.X/Y/Z or a non-zero XYZ vector. Defaults to Axis.X.count2— Optional instance count for the second direction.spacing2— Optional spacing for the second direction, in mm.direction2— Second pattern direction as Axis.X/Y/Z or a non-zero XYZ vector. Defaults to Axis.Y.alignment— First-direction native alignment: “left”, “center” or “right”. Defaults to “right”.alignment2— Second-direction native alignment: “left”, “center” or “right”. Defaults to “right”.reversed— Reverse the first native pattern direction. Defaults to False.reversed2— Reverse the second native pattern direction. Defaults to False.
Example
plate.rectangular_pattern(cut, count=3, spacing=24, direction=Axis.X, count2=2, spacing2=28)