Monospaced Value Display

#Multi-Mode Numeric Readout
v2.3 4/25/24 ddcarr

Displays numeric values in selected number format of fixed-point or scientific (mantissa and exponent), including engineering styles. The type can be mono-spaced or proportional, custom color, size reduced or enlarged.
Alignment can be left, center, right, or at the decimal-point (the module also handles the case of zero decimal place display).

Canvas size is only large enough to grab for placement, as drawing can extend outside the canvas.


I/O

Input Signal Range Notes
x +/- any value the input value
N Pos Integer Number of digits past the decimal point
mode Pos Integer Value applied per assignments below
r,g,b,a Pos float Color and brightness to use
align Pos float [-1:right, 0:center, 1:left, 2:decimal point]
prop Pos Integer. [1:proportional, 0:mono-spaced]
units Pos Integer [0:none, 1:Hz, 2:s]
zoom +/- any value Shrinks or grows text. if zoom = 0, default size (1) is used

Modes:

# name note
0 fix fixed point
1 Sci scientific notation [mantissa]e[exponent] (e replaces ‘10^”)
2 Eng Engineering (exponents divisible by 3)
3 fixEng Fixed/Engineering mode-treat values with exponent 0 as fixed point

Version History

V2.3 4/25/24
Multi-Mode Value Display v2.3.audulus4 (11.5 KB)
Demo:
Multi-Mode Value Display v2.3 demo.audulus4 (48.0 KB)