Skip to content

Python package

ra.advanced_gems_on_curve

Runs of stones along a curve with per-stone sizes, shapes and rotations.

import rhinoartisan as ra

Wraps ArtisanPlugin.Scripting.AdvancedGemsOnCurveApi.

Functions

Function
all()AdvancedGemsOnCurve handles for every object of this kind in the active document (empty when there is no document).
by_layer()AdvancedGemsOnCurve handles on the layer with the given full path (empty when the layer does not exist).
count()Number of objects of this kind in the active document.
create()Lays a PATTERN of gem groups along a curve — the ArtisanAdvancedGemsOnCurve tool, headless.
find()The handle for id, or None when the id does not belong to an object of this kind.
selected()AdvancedGemsOnCurve handles for the objects of this kind currently selected in the active document.

ra.advanced_gems_on_curve.all()

ra.advanced_gems_on_curve.all() -> List[AdvancedGemsOnCurve]

AdvancedGemsOnCurve handles for every object of this kind in the active document (empty when there is no document).

ra.advanced_gems_on_curve.by_layer()

ra.advanced_gems_on_curve.by_layer(layer_name: str) -> List[AdvancedGemsOnCurve]

AdvancedGemsOnCurve handles on the layer with the given full path (empty when the layer does not exist).

ParameterType
layer_namestrrequired

ra.advanced_gems_on_curve.count()

ra.advanced_gems_on_curve.count() -> int

Number of objects of this kind in the active document.

ra.advanced_gems_on_curve.create()

ra.advanced_gems_on_curve.create(curve_id: IdLike, sizes: Sequence[float], quantities=None, sizes2=None, shapes=None, rotations=None, distance=None, move_by_z=None, rotation_on_curve=None, alignment_on_curve=None, alignment_vertical=None, start_centered=None, upside_down=None, flip_curve=None, orientation_ids=None, t0=None, t1=None) -> AdvancedGemsOnCurveResult

Lays a PATTERN of gem groups along a curve — the ArtisanAdvancedGemsOnCurve tool, headless. Unlike GemsOnCurveApi (one size, one shape) each group i has quantities[i] gems graduating from sizes[i] to sizes2[i] mm (same size when omitted), of shapes[i] (default ROUND) rotated rotations[i] degrees; the groups run one after another from the curve start. Diamonds only (the tool has no material choice). Millimetres; omitting keeps the tool default (or the user’s saved defaults): distance 0.2 between gems. alignment_on_curve START (default) / CENTER / END, alignment_vertical ON_GIRDLE (default) / TOP. t0/t1 limit the run to a curve parameter range. Returns the group id plus the gem ids.

ParameterType
curve_idIdLikerequired
sizesSequence[float]required
quantitiesSequence[int]optional — None = the tool default
sizes2Sequence[float]optional — None = the tool default
shapesSequence[str]optional — None = the tool default
rotationsSequence[float]optional — None = the tool default
distancefloatoptional — None = the tool default
move_by_zfloatoptional — None = the tool default
rotation_on_curvefloatoptional — None = the tool default
alignment_on_curvestroptional — None = the tool default
alignment_verticalstroptional — None = the tool default
start_centeredOptional[bool]optional — None = the tool default
upside_downOptional[bool]optional — None = the tool default
flip_curvebooloptional — None = the tool default
orientation_idsSequence[IdLike]optional — None = the tool default
t0floatoptional — None = the tool default
t1floatoptional — None = the tool default

ra.advanced_gems_on_curve.find()

ra.advanced_gems_on_curve.find(id: IdLike) -> AdvancedGemsOnCurve

The handle for id, or None when the id does not belong to an object of this kind.

ParameterType
idIdLikerequired

ra.advanced_gems_on_curve.selected()

ra.advanced_gems_on_curve.selected() -> List[AdvancedGemsOnCurve]

AdvancedGemsOnCurve handles for the objects of this kind currently selected in the active document.

Handles

Objects returned by the functions above. Assigning a settable property regenerates the object; the change is one undo step inside ra.transaction().

AdvancedGemsOnCurve (handle)

PropertyTypeSettable
curve_idstr
layer_namestr
member_countintRhino objects in the group
mother_gem_idstr
object_typestr
parameters_jsonstrthe kernel model, as stored in the group
positionPoint3d
Method
delete()
get_parameter(path: str) -> strdotted JSON path; None when absent
move(translation: VectorLike)

Plus what every handle has: id, delete(), update(**kwargs), parameters(), equality and hashing by id, and raw (the underlying .NET object).