Expand description
Depiction proportions (xenopict / RDKit house style).
Python host draw stack removed; this module is SoT.
Constants§
- BOND_PX
- Bond length in drawing / CSS-px units (alias of
SCALE). - CHAIN_
END_ GAP_ FRAC - CHAIN_
END_ GAP_ PX - END_
GAP_ FRAC - END_
GAP_ PX - FONT_
FRAC - Atom-label em as a fraction of bond length.
- FONT_PX
- FONT_
STEM_ EM - Liberation Sans Regular vertical stem width in em.
- FONT_
STEM_ EM_ BOLD - Liberation Sans Bold vertical stem width in em (measured on H).
- HALO_
FRAC - HALO_
GAP_ PX - Halo outline grow (half the label-gap air) + soft white fill.
- HALO_
OPACITY - HALO_
STROKE - HASH_
PER_ BOND - LABEL_
GAP_ FRAC - LABEL_
GAP_ PX - OFFSET_
FRAC - RDKit
multipleBondOffset. - OFFSET_
PX - PAD_
FRAC - PAD_PX
- SCALE
- House bond length / CSS-px scale (was 20; ~1.5× for publication weight).
- SCRIPT_
SCALE - Alias for
SUBSCRIPT_SCALE(historical name used by older call sites). - SHADE_
BOTH_ FRAC - Shared PlotDot base when atom and bond scores paint (8/9 of
SHADE_FRAC). - SHADE_
FRAC - PlotDot outer radius as a fraction of bond length.
- STAR_
FRAC - Dummy / R-group
*height as a multiple of Liberation cap-height. - STROKE_
FRAC - Bond stroke as a fraction of bond length — tracks the label stem so ink
weight matches letter stems when
FONT_FRACchanges. - STROKE_
PX - SUBSCRIPT_
SCALE - Fake-subscript scale for H-counts (RDKit
DrawText::SUBS_SCALE). - SUPERSCRIPT_
SCALE - Fake-superscript scale for charges / caret markup.
- WEDGE_
HALF_ PX - WEDGE_
WIDTH_ FRAC - Full wedge width at the fat end, as a fraction of bond length.
- WEIGHT_
AT_ ONE - Absolute ink multiplier at user-facing
weight = 1(house look). - WEIGHT_
MIN - Lowest user-facing
weight(maps to absolute ink1= Regular stem).
Functions§
- diagram_
weight - Map user-facing mol
weight→ absolute ink multiplier (≥ 1). - halo_
gap_ for_ weight - Outer halo buffer for mol
weight:HALO_GAP_PX× √ink. - halo_
stroke_ for_ weight - Halo stroke for mol
weight:HALO_STROKE× √ink (sublinear vs ink). - halo_
stroke_ from_ stroke - Halo stroke width tracks active bond ink (2×, same ratio as
HALO_FRAC). - hash_
count - Dash count scaling with drawn bond length (hashed wedges).
- label_
weight_ grow_ px - Outward glyph buffer (px) so absolute ink stems grow past Regular.
- label_
weight_ standoff_ px - Extra bond↔label standoff (px) when absolute ink exceeds Regular.
- stroke_
frac_ from_ stem - Bond stroke fraction from a stem width in em (rounded like
STROKE_FRAC). - stroke_
px_ for_ weight - Bond stroke in drawing px for user-facing mol
weight. - stroke_
px_ from_ stem - Bond stroke in drawing px keyed to a label stem.