Appearance
Function: coordToEmu() ​
coordToEmu(
value,axisEmu):Emu
The single user-coordinate → EMU boundary. Convert each user-supplied coordinate exactly once.
Accepts (see Coord):
- a bare
number→ always inches (the documented unit); no magnitude guessing "<n>%"→ percentage ofaxisEmu"<n>in"/"<n>pt"/"<n>px"/"<n>emu"→ explicit units (the escape hatch for non-inch values).pxis resolved at DEFAULT_PX_PER_INCH (96), for authoring against a known web/source canvas size.
Throws on non-finite or unparseable input rather than silently emitting a degenerate 0-size.
Parameters ​
| Parameter | Type | Description |
|---|---|---|
value | string | number | user coordinate |
axisEmu | number | axis length in EMU, used only to resolve percentages |