.NET API
ToiEtMoiApi
Toi et Moi ring top (the ArtisanToiEtMoi tool, headless): two INDEPENDENT stones straddling the top of a finger size, one leaning to each side. The classic combinations mix shapes (pear + round).
from ArtisanPlugin.Scripting import ToiEtMoiApi
See also the guide, Gems › Toi et Moi, and the Python package, ra.toi_et_moi.
Methods
| Method | |
|---|---|
Create | Creates the editable Toi et Moi group. |
Edit | Edits an existing Toi et Moi parametrically, like reopening it in the ArtisanToiEtMoi panel: objectId is either of its gems (or its finger circle). |
Create
IReadOnlyList<Guid> ToiEtMoiApi.Create(
string shapeA,
double caratsA,
string shapeB,
double caratsB,
string materialA = "Diamond",
string materialB = "Diamond",
double angleA = 14,
double angleB = -14,
double rotationYA = 20,
double rotationYB = -20,
double distance = 0,
double fingerDiameter = 0)
Creates the editable Toi et Moi group. Per stone: shape (GemShape name), carats and material; placement starts from the user’s saved Toi et Moi defaults when there are any (an argument left at its signature default keeps the saved value), otherwise from the tool’s (stone A at +14 degrees leaning +20, stone B mirrored), unless the angle/rotationY arguments say otherwise. fingerDiameter 0 = the document’s finger size. Returns the ids of the two gems (the group also carries the finger reference circle).
| Parameter | Type | Default |
|---|---|---|
shapeA | string | required |
caratsA | double | required |
shapeB | string | required |
caratsB | double | required |
materialA | string | "Diamond" |
materialB | string | "Diamond" |
angleA | double | 14 |
angleB | double | -14 |
rotationYA | double | 20 |
rotationYB | double | -20 |
distance | double | 0 |
fingerDiameter | double | 0 |
Returns IReadOnlyList<Guid>.
Edit
IReadOnlyList<Guid> ToiEtMoiApi.Edit(
Guid objectId,
double distanceA = double.NaN,
double distanceB = double.NaN,
double angleA = double.NaN,
double angleB = double.NaN,
double rotationA = double.NaN,
double rotationB = double.NaN,
double rotationYA = double.NaN,
double rotationYB = double.NaN,
string shapeA = null,
double caratsA = double.NaN,
string materialA = null,
string shapeB = null,
double caratsB = double.NaN,
string materialB = null,
double fingerDiameter = double.NaN)
Edits an existing Toi et Moi parametrically, like reopening it in the ArtisanToiEtMoi panel: objectId is either of its gems (or its finger circle). Pass only what changes — NaN / null keep the stored value. The distances are each stone’s height above the ring (“Distance above ring” in the panel): change them to raise or lower a stone, never move the gem directly. A new shape or material keeps the carats unless they are given too. The gems are rebuilt in place and KEEP their ids (returned as [stone A, stone B]); settings built on them are flagged for regeneration (coral in the outliner, rebuilt on Refresh).
| Parameter | Type | Default |
|---|---|---|
objectId | Guid | required |
distanceA | double | double.NaN |
distanceB | double | double.NaN |
angleA | double | double.NaN |
angleB | double | double.NaN |
rotationA | double | double.NaN |
rotationB | double | double.NaN |
rotationYA | double | double.NaN |
rotationYB | double | double.NaN |
shapeA | string | null |
caratsA | double | double.NaN |
materialA | string | null |
shapeB | string | null |
caratsB | double | double.NaN |
materialB | string | null |
fingerDiameter | double | double.NaN |
Returns IReadOnlyList<Guid>.