Cached parseColor. Use this from renderer hot paths (per-frame draw
callbacks, gradient ramp builds) so repeated color strings — which are
common when many objects share a fill — don't re-tokenize each frame.
Cache is keyed by input-string identity, capped at ~1024 entries, and
cleared wholesale on overflow (no LRU tracking — simple is fine since
the working set in any one app is typically much smaller than the cap).
Cached
parseColor. Use this from renderer hot paths (per-frame draw callbacks, gradient ramp builds) so repeated color strings — which are common when many objects share a fill — don't re-tokenize each frame.Cache is keyed by input-string identity, capped at ~1024 entries, and cleared wholesale on overflow (no LRU tracking — simple is fine since the working set in any one app is typically much smaller than the cap).