← Standard library

FormatSpec

static class FormatSpec
import FormatSpec from Wax;

Parses an ASCII numeric format letter and optional decimal precision/width, such as F2 or X4. Empty or malformed suffixes are reported as unspecified precision; valid suffixes saturate at 99.

FormatSpec.wax:13

Inherits from object. Follow these links for inherited members.

Members

SpecCharmethod

public static fn SpecChar(string fmt) : int32

Returns the first byte as an integer, or zero for an empty specification. It does not validate the letter.

FormatSpec.wax:20

Precisionmethod

public static fn Precision(string fmt) : int32

Returns the decimal suffix after the first byte, capped at 99. Returns -1 for a missing suffix or any nondigit in the suffix, even after the cap has been reached.

FormatSpec.wax:35