mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-24 09:46:59 -06:00
Smart Guides: Alt over another object or the artboard shows the selection's distances to it
Distance Guides, from the public "Use Distance Guides for accurate placement" and "Smart Guides options" (Invoke Distance Guides) pages: with Smart Guides on, something selected and the Selection tool, holding Alt/Option over another object shows the horizontal and vertical distances between the selection and it, and over an empty part of an artboard the selection's distances from the artboard's left, right, top and bottom edges. - guides::distance_guides measures the selection's bounds to a box: on an axis on which they lie apart, the gap between their facing edges; otherwise the offsets of both pairs of matching edges. Each line runs across the middle of the overlap on the other axis (else the selection's middle), with a dashed line out to the target's edge when it passes beside it. An artboard is always measured edge to edge. Labels are in the General unit, in the smart guide colour. - The Selection tool keeps what its Alt hover points at and draws the guides while idle; letting Alt go (the canvas re-hovers on a modifier change), a press or moving off clears them. - Overlay::Distance: the line with end ticks and its length in a pill; the canvas draws it. - Preferences › Smart Guides › Invoke Distance Guides (`distanceGuides`, on by default), with i18n rows; View › Smart Guides gates it too. - Hover only, as the pages describe: nothing while moving or nudging. Tests: select::tests::alt_over_* (gap and edges beside and below, artboard edges in pt and mm), distance_guides_need_alt_a_selection_and_ smart_guides, tests_prefs::invoke_distance_guides_measures_the_selection_ to_the_object_under_alt, canvas::tests::alt_over_another_object_draws_ the_distance_guide_label (frame test of the drawn label and line).
This commit is contained in:
committed by
bflatastic
parent
bfc2d6e439
commit
a301760aa6
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user