Skip to main content

canvasMol()

canvasMol(x, y, w, h, canvas, molString, scaffoldMolString, options): Promise<void>

Renders a molecule to canvas (using RdKit) TODO: should NOT be async See example:

Parameters

ParameterTypeDefault value
xnumberundefined
ynumberundefined
wnumberundefined
hnumberundefined
canvasObjectundefined
molStringstringundefined
scaffoldMolStringnull | stringnull
optionsobjectundefined
options.normalizeDepictionbooleantrue
options.straightenDepictionbooleantrue

Returns

Promise<void>

Source

src/chem.ts:833