Repository navigation
M3: stroke on type, Stroke panel units, mixed values and Control bar (M3.40, M3.41) - #28
Merged
Merged
Conversation
With type selected, stroke.set (without an item) gives every run the weight, cap, join, miter limit and dashes instead of adding an object stroke; while the Type tool edits text, the Stroke panel styles the selected characters through text.setRangeStyle `strokeOptions`, and the panel reads the first run (or the selection's style). CharStyle gains stroke_cap, stroke_join, stroke_miter_limit and stroke_dash (defaulted, skipped when default). Character strokes and object strokes on type now draw through the shared stroke geometry on the canvas, in PDF and in SVG (live text writes cap/join/miter/dash and tspans reset what the first run sets; object strokes are drawn on the glyph outlines), so every stroke option, opacity and blend applies. Outlines, the Eyedropper and graphic styles keep the options. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…and reaches the Control bar - Weights and dash lengths show in Units > Stroke in the Stroke panel, the Control bar and the Properties panel (Session::stroke_unit). - Values the selected objects don't share show blank (weight, miter limit, dashes) or light no button (cap, join, align), from a per-revision cached DocState::stroke_mixed. - Align Stroke Inside/Outside are disabled for open paths and type. - The Control bar weight is a preset spinner with a width profile dropdown, and its Stroke link (and the Properties panel's) opens the Stroke panel as an anchored popover instead of docking it. - The panels show a group's first painted object's stroke, as the Stroke proxy does (Session::shown_stroke). - stroke.set on a group skips images and symbol instances. - document.inspect reports each object's strokeOptions (cap, join, miterLimit, align, dash, dashOffset, alignDashes, arrows, arrowAlign, profile) in stroke.set terms. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of M3 (Paint & appearance). The Stroke panel now edits the stroke of type characters, and it follows the stroke units, shows mixed values blank and reaches the Control bar.
CharStylegainsstroke_cap,stroke_join,stroke_miter_limit(default 10) andstroke_dash, defaulted and only written when set. OneCharStyle::appearance()builds the characters' fill and stroke, keeping the overprint flags and the stroke options.stroke.set: with type selected and noitem, it sets weight, cap, join, miter limit and dashes on every run; an explicititemedits an object stroke. Unknown cap or join names are now rejected.text.setRangeStyle {strokeOptions}styles a range of characters, and the Stroke panel uses it while the Type tool edits text.DocState::stroke_mixed, cached per revision).stroke.seton a group skips images and symbol instances.document.inspectreportsstrokeOptions(cap, join, miter limit, align, dash, offset, alignment, arrowheads, profile), including for groups and layers that carry their own stroke.docs/mcp.mdhas a "Strokes on type" section.Known limits:
Checks
Rebased onto
09778f2(#27).cargo xtask cipasses all 7 steps on this branch: 1,550 tests, 0 failed.🤖 Generated with Claude Code