Expand description
Text-metric helpers for axis-label fit (B3-1): ggplot-rs owns the
outer-label-overflow and check.overlap logic centrally, instead of a
downstream consumer post-processing rendered SVG (the old approach had
to re-parse <text> elements out of the markup).
Ported verbatim from the consumer’s ticks.rs em table and
TickLabel::bbox, which is the only reason the measurements match what
callers previously saw.
Functions§
- text_
width - Estimated width (px) of
textset at font sizesize, in the house sans (Hanken Grotesk, or the system UI font it falls back to). This is a heuristic per-character average-width table, not real font metrics — good enough for layout decisions (fit, overlap, auto-wrap), not for pixel-perfect text extents.