Skip to content

Pluggable font stacks for embedders - #33

Open
calumk wants to merge 1 commit into
quickdrawjs:mainfrom
calumk:pluggable-fonts
Open

calumk wants to merge 1 commit into
quickdrawjs:mainfrom
calumk:pluggable-fonts

Conversation

@calumk

@calumk calumk commented Nov 1, 2026

Copy link
Copy Markdown

Fixes #32.

Adds a tiny registry API over the existing font style ids (setFontStacks / resetFontStacks / fontStackOf + FONT_IDS roster), so hosts can remap any id — or register new ones — to a full CSS font-family stack with one call. Measurement, canvas drawing, the editing textarea and type layout all resolve through the single point; unknown ids fall back to draw, and FontId widens to keep custom ids typechecking.

No default behavior change: without setFontStacks every stack resolves exactly as before. No new dependencies, no binaries, no UI changes.

@vercel

vercel Bot commented Nov 1, 2026

Copy link
Copy Markdown

@calumk is attempting to deploy a commit to the naman's projects Team on Vercel.

A member of the Team first needs to authorize it.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pluggable font stacks for embedders

1 participant