pyboxbuilder.compartments.finger_outline.CutProfile

class pyboxbuilder.compartments.finger_outline.CutProfile(width: float | None = None, base_radius: float | None = None, mouth_flare: float | None = None, roll_rise: float | None = None)[source]

Bases: object

The four numbers that decide a finger cut’s outline (FR-051).

Grouped rather than passed loose because every defect that reached a user in this shape was a wiring one, not a maths one: a rise clamped without its radius, a value passed where None was the contract and the derived rule silently switched off, a base sized until it touched. A record makes the contract visible at the call site and puts the derivations in one place.

Every field is None for “derive it”, because the derivation depends on the others and on the cut’s depth — which the builder knows and the caller usually does not (FR-059).

with_half_width(half_width: float) → CutProfile[source]

Return a copy whose width is set from a half-width.

base_radius : float | None = None

How the base curves into the sides. None derives it from the depth (FR-054/a7) — the flattest arc that still meets the roll.

property half_width : float | None

The throat’s half-width, which is what the outline maths works in.

mouth_flare : float | None = None

How far the mouth rolls outward at the rim. None takes a share of the throat (FR-059).

roll_rise : float | None = None

How far that roll reaches down — the gentleness of it, independent of the width (FR-057). None derives it from the flare.

width : float | None = None

How wide the cut is, wall to wall of the finger. None uses twice DEFAULT_THROAT_RADIUS_MM.