Skip to content

Python package

ra.split_shank

Split shanks.

import rhinoartisan as ra

Wraps ArtisanPlugin.Scripting.SplitShankApi.

Functions

Function
all()SplitShank handles for every object of this kind in the active document (empty when there is no document).
by_layer()SplitShank 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()Builds a split shank — the ArtisanSplitShank tool, headless.
find()The handle for id, or None when the id does not belong to an object of this kind.
selected()SplitShank handles for the objects of this kind currently selected in the active document.

ra.split_shank.all()

ra.split_shank.all() -> List[SplitShank]

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

ra.split_shank.by_layer()

ra.split_shank.by_layer(layer_name: str) -> List[SplitShank]

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

ParameterType
layer_namestrrequired

ra.split_shank.count()

ra.split_shank.count() -> int

Number of objects of this kind in the active document.

ra.split_shank.create()

ra.split_shank.create(finger_diameter=None, opening_length=None, arm_height=None, split_width=None, split_start=None, top_size=None, bottom_size=None, plane=None, element=None) -> SplitShank

Builds a split shank — the ArtisanSplitShank tool, headless. Millimetres / degrees; omitting keeps the tool default (or the user’s saved defaults). finger_diameter 0 = the document’s finger size. Returns an SplitShank handle to the new shank. element = name of a saved element (ra.elements.list) to start from; explicit arguments override it.

ParameterType
finger_diameterfloatoptional — None = the tool default
opening_lengthfloatoptional — None = the tool default
arm_heightfloatoptional — None = the tool default
split_widthfloatoptional — None = the tool default
split_startfloatoptional — None = the tool default
top_sizefloatoptional — None = the tool default
bottom_sizefloatoptional — None = the tool default
planeOptional[PlaneLike]optional — None = the tool default
elementstroptional — None = the tool default

ra.split_shank.find()

ra.split_shank.find(id: IdLike) -> SplitShank

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

ParameterType
idIdLikerequired

ra.split_shank.selected()

ra.split_shank.selected() -> List[SplitShank]

SplitShank 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().

SplitShank (handle)

Split shank: a band that opens into two arms toward the setting. Multiple gems, so no single MotherGem.

PropertyTypeSettable
curveSplitShankCurve
gemsSplitShankGems
layer_namestr
mother_gem_idstr
object_typestr
positionPoint3d
ring_diameter_mmfloat
ring_size_labelstr
ring_size_regionstr
sectionsList[SplitShankSection]The three swept profiles, ordered bottom -> side -> top.
Method
delete()
move(translation: VectorLike)
set_element(element: str)Applies a saved SplitShank element (ra.elements.list(“SplitShank”)) to this shank: its parameters replace the current ones, the ring size stays, and the shank regenerates in place (same id).
set_section(index: int, position: float, width: float, height: float, type=None, profile_name=None)Edits one of the three sections in place.
set_section_enabled(index: int, enabled: bool)

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

SplitShankCurve (section)

The rail a split shank is swept along: how the arms rise, open and split.

PropertyTypeSettable
arm_heightfloatyesrise of the arm tips above the ring top, mm
arm_offsetfloatyesextra outward bulge beyond the reference shape, mm
lateral_displacementfloatyesY displacement of the arm tips, mm
lateral_inclinationfloatyesinclination of the arms along the finger axis, degrees
opening_lengthfloatyesfrontal X distance between the arm tips, mm (0 = touching)
split_startfloatyeswhere along the rail the split begins, 0..1
split_widthfloatyesseparation between the front and back arm pairs, mm

SplitShankGems (section)

The pave run along a split shank’s arms, with a top-to-bottom size gradient.

PropertyTypeSettable
automatic_prong_diameterboolyes
bottom_sizefloatstone size at the ring bottom, mm
bright_cutfloatyesmm
channel_clearancefloatyesmm
channel_shapestryes
drill_typestryes”NONE”, “ROUND” or “QUAD”
enabledboolyes
flip_endboolyes
flip_startboolyes
gem_insidefloatyesmm
inner_heightfloatyesmm
inner_widthfloatyesmm
margin_bottomfloatrun start, in mm of arc length from the rail start (Start gumball)
margin_topfloathow far below the arm tip the gem run stops, mm (End gumball)
min_distancefloatyesmm
move_in_zfloatyesmm
prong_diameterfloatyesmm
prong_heightfloatyesmm
prong_typestryes”NONE”, “SHARED” or “SCALLOPED”
shank_sizefloatyesmm
shapestryes”ROUND”, “PRINCESS”, …
spacingfloatyesgap between gems (arms and trunk alike), mm
top_sizefloatstone size at the arm tip, mm
transition_sizefloatyesmm
v_cuttersboolyes
verticalfloatyesmm
Method
clear_gem_sizes()drop every per-stone override (back to the size gradient)
set_gem_size(position: float, diameter: float)per-stone override; position = normalised rail t (0..1), snaps to the nearest stone
set_margins(top: float, bottom: float)
set_sizes(top_size: float, bottom_size: float)