Repository navigation
Part of #394: Smart Guides display options and Snapping Tolerance - #453
Merged
Merged
Conversation
…rance Color, Alignment Guides, Anchor/Path Labels, Measurement Labels, Transform Tools, Object Highlighting and Snapping Tolerance are read: - tools: `guides::GuideStyle` on `Targets` (`styled(cx)`) colours the lines and labels and leaves them out when their option is off, the snap itself unchanged; `ToolContext` gains the six fields and `snap_tol()`, replacing the 5 px literal for every smart guide snap (drawn points, moves, bounding-box handles, ruler guides, artboards, reference points). The tools gate their `Overlay::Measure` readouts on Measurement Labels (drawing, moving, ruler guides, artboards) or Transform Tools (scaling, rotating, Free Transform, transform tools). - engine: `with_tool_cx` fills them from `Prefs` (the colour parsed, magenta as fallback); the colour's default is `#ff3dfc`, what the tools drew. - ui-egui: the hover outline needs Object Highlighting and Smart Guides. - Tests in tools (guides, select), engine (tests_prefs) and the canvas; docs/mcp.md and ROADMAP. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…m's move offset and slice readouts follow Measurement Labels (review of storytold#453) - `Targets::align_rects` tells `snap_point_with` an axis lined up even when nothing moved or Alignment Guides hide the line, so the "align" label stays. - Free Transform's move offset is a measurement label (as the Selection tool's), its scale/rotate readouts Transform Tools; slice move/resize readouts follow Measurement Labels. - Snap to Point (Smart Guides off) keeps the default look for moves too, as for drawn points and guides. - Test: guides dragged out of a ruler (storytold#451) follow Snapping Tolerance, Anchor/Path Labels and Measurement Labels; docs/mcp.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bflatastic
force-pushed
the
fix/issue-394-smart-guides
branch
from
October 8, 2026 08:50
217795a to
42fced4
Compare
Member
|
Thanks @wstock, and welcome! This is a really clean piece of work.
Checked live in the app (colour, labels and alignment lines each switch off as expected while snapping still works) and over MCP ( |
This was referenced Oct 8, 2026
azmiruddinalif
pushed a commit
to azmiruddinalif/vectorcraft
that referenced
this pull request
Oct 11, 2026
azmiruddinalif
pushed a commit
to azmiruddinalif/vectorcraft
that referenced
this pull request
Oct 15, 2026
azmiruddinalif
pushed a commit
to azmiruddinalif/vectorcraft
that referenced
this pull request
Oct 18, 2026
azmiruddinalif
pushed a commit
to azmiruddinalif/vectorcraft
that referenced
this pull request
Nov 3, 2026
azmiruddinalif
pushed a commit
to azmiruddinalif/vectorcraft
that referenced
this pull request
Nov 14, 2026
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 #394. Seven of the Smart Guides preferences that were stored but read by nothing now do what their labels say, for the mouse and for agents (
prefs.set, thenpointer_gesture). The issue stays open for the rest.Preferences › Smart Guides
#ff3dfc, the magenta the tools have always drawn, so nothing changes until it is edited.snapToPointTolerance.How
vectorcraft_tools::guides::GuideStyle(colour, lines, labels) rides onTargets(Targets::styled(cx)), so every snap method draws through two helpers instead of theMAGENTAliteral;ToolContextgains the six fields andsnap_tol(). The tools gate theirOverlay::Measurereadouts onmeasurement_labels/transform_tools_guides.Prefsinwith_tool_cx(the colour parsed withvectorcraft_color::Color::from_hex, falling back to magenta); the canvas's hover outline checksobject_highlightingandview.smart_guides.docs/mcp.md(Selection preferences: a Smart Guides list, with what is still unread), ROADMAP (Shipped so far, UI chrome row).Skipped (the tools draw neither yet): Construction Guides and their Angles, Spacing Guides.
Tests (each fails without the change)
guides::display_options_colour_and_hide_the_guides_but_keep_the_snap,select::smart_guide_display_preferences_drive_the_readouts_and_the_pull(readouts per option; a handle 6 px from a target is pulled at tolerance 8, not at 4 or 0).tests_prefs::smart_guide_display_preferences_filter_the_overlays: throughprefs.setand real pointer gestures — colour, alignment lines off while the square still lines up, measurement and transform readouts, the tolerance, and the "anchor" label of a drawn corner.canvas::object_highlighting_preference_hides_the_hover_outline(headless egui frame with a pointer move).cargo fmt --check;cargo clippy --all-targets -- -D warningson tools, engine and ui-egui;cargo test -p vectorcraft-tools,-p vectorcraft-engine tests_prefsand-p vectorcraft-ui-egui canvas::all pass (Linux, rebased on today's main after Part of #394: Preferences that act on selection, the wheel, tool tips and the grid #413/Part of #394: Preferences for snapping, handles, rubber bands, pattern tiles, tints and type #422). The only clippy complaint on a 1.99 toolchain isclippy::chunks_exact_to_as_chunksincursors.rs(from [BUG] Mouse sluggish when moving over Vectorcraft #444, untouched here).Parity source (feature names only): the Smart Guides preferences page, https://helpx.adobe.com/illustrator/using/smart-guides.html.
Developed with AI assistance (Claude Code); reviewed and tested locally.