Commit Graph
3 Commits
Author SHA1 Message Date
Trevor BrownandClaude Fable 5.1 25b128e538 Pencil colour: document the dark threshold; tests for a frame without a fill, a see-through fill and the threshold
Review follow-up on #1775: the dark rule is the one text uses (on_dark_background); a frame with no fill, or a fill under 50% alpha, is looked through to what is behind it, and the threshold is Color::is_dark (#757575 is dark, #767676 is light).

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 00:14:22 -04:00
Trevor BrownandClaude Fable 5.1 fcab85ddd0 M4: the Pencil draws white on a dark page or frame, and previews in that colour (#1741)
Figma: "a round 3px stroke weight in black, unless you are sketching on a dark canvas or frame". The Pencil always drew black. It now takes the colour from the same dark-background rule new text uses (the nearest ancestor with a mostly opaque solid fill, else the page), and the overlay carries that colour for the stroke in progress so the preview matches. Engine and UI regression tests.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-31 11:34:55 -04:00
BFlat cb5435d5ff M4: stretch and scatter brushes, pen pressure (#120)
Strokes can use a brush: eight presets drawn in code (four stretched along the path, four scattered with spacing, size, rotation and offset jitter from a fixed seed), drawn by the shared stroke-outline code in canvas, PNG, SVG, PDF and outline stroke, with caps on copies and steps. Pointer events carry pen pressure; the Pencil records it as the stroke's width profile, which brushes follow (Windows pens and browser styluses; constant width elsewhere).
2026-10-11 13:43:48 +07:00