.NET API
WeddingBuilderApi
Headless builders for the wedding tools. WeddingApi / WeddingBandApi stay query-only (All/Find/Selected); the handles they return are the same ones these Create methods hand back, so WeddingBandApi.Find(id) finds what CreateBand made.
from ArtisanPlugin.Scripting import WeddingBuilderApi
See also the Python package, ra.wedding.
Methods
| Method | |
|---|---|
CreateBand | Builds a single wedding band (the ArtisanWeddingBand tool, headless): a plain band lofted from a RING_PROFILE asset at the document’s finger size, optionally with a row of stones around it. |
CreateSet | Builds a wedding set (the ArtisanWeddingRing tool, headless): two bands baked together as one group — his and hers — each with its own section, metal, finger size and optional stones. |
CreateBand
IWeddingBand WeddingBuilderApi.CreateBand(
double width = 0,
double height = 0,
double fingerDiameter = 0,
string profile = null,
string metal = null,
bool withGems = false,
double gemSize = 0,
string gemShape = null,
string distribution = null,
int numberOfGems = 0,
string prongType = null,
Plane? plane = null,
string element = null)
Builds a single wedding band (the ArtisanWeddingBand tool, headless): a plain band lofted from a RING_PROFILE asset at the document’s finger size, optionally with a row of stones around it. Millimetres; 0 keeps the tool default: width 3, height 2. fingerDiameter 0 = the document’s finger size. profile picks a RING_PROFILE asset by name (omitted = the default profile); metal a Metal name like “GOLD_YELLOW_18” (omitted = the document’s Metal 01). withGems true enables the stones: gemSize (default 1.2), gemShape “Round” | “Princess”, distribution “Full” | “Half” | “Onequarter” | “Custom” (+ numberOfGems), prongType “None” | “Shared” | “Channel”. plane omitted = world XY. element = name of a saved WeddingBand element (ElementsApi.List(“WeddingBand”)) to start from; explicit arguments override it (its finger size is always replaced). Returns the IWeddingBand handle of the new band group.
| Parameter | Type | Default |
|---|---|---|
width | double | 0 |
height | double | 0 |
fingerDiameter | double | 0 |
profile | string | null |
metal | string | null |
withGems | bool | false |
gemSize | double | 0 |
gemShape | string | null |
distribution | string | null |
numberOfGems | int | 0 |
prongType | string | null |
plane | Plane? | null |
element | string | null |
Returns IWeddingBand.
CreateSet
IWedding WeddingBuilderApi.CreateSet(
double width = 0,
double height = 0,
double secondWidth = 0,
double secondHeight = 0,
double fingerDiameter = 0,
double secondFingerDiameter = 0,
string profile = null,
string secondProfile = null,
string metal = null,
string secondMetal = null,
bool withGems = false,
double gemSize = 0,
bool secondWithGems = false,
double secondGemSize = 0,
Plane? plane = null)
Builds a wedding set (the ArtisanWeddingRing tool, headless): two bands baked together as one group — his and hers — each with its own section, metal, finger size and optional stones. Millimetres; 0 keeps the tool default (width 3, height 2 for both). fingerDiameter / secondFingerDiameter 0 = the document’s finger size. profile / secondProfile pick RING_PROFILE assets by name (omitted = the default profile); metal / secondMetal are Metal names (omitted = the document’s Metal 01). withGems + gemSize (and the second* pair) add a full row of round stones to that ring. plane omitted = world XY. Returns the IWedding handle of the new set (FirstRing / SecondRing).
| Parameter | Type | Default |
|---|---|---|
width | double | 0 |
height | double | 0 |
secondWidth | double | 0 |
secondHeight | double | 0 |
fingerDiameter | double | 0 |
secondFingerDiameter | double | 0 |
profile | string | null |
secondProfile | string | null |
metal | string | null |
secondMetal | string | null |
withGems | bool | false |
gemSize | double | 0 |
secondWithGems | bool | false |
secondGemSize | double | 0 |
plane | Plane? | null |
Returns IWedding.
Handles and sections
What the methods above hand back. A handle’s setters regenerate the object; wrap changes in a Transaction so they land as one undo step.
Also used here: IWedding, IWeddingRing, IWeddingProfile, IWeddingGems, IWeddingBand.