mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-25 10:17:02 -06:00
Dragging a numeric field's label left or right steps the field's value, as Photoshop's scrubby labels do (beyond Illustrator): one unit every 2 points, ten with Shift, a tenth with Ctrl/Cmd (counts stay whole), in the field's unit and precision. The panels apply each value as they apply a typed one, so the art follows live and the caller's limits hold (dragging back from a limit changes the value at once). - scrub.rs: the label zone over the label noted just before a field (dim_label, label_row, widgets::field_label, the Character and Paragraph panels' icons, the Transform and Properties rotate/shear icons), the ↔ cursor on hover, a click on the label focuses the field. The text box itself never scrubs; a field without a label doesn't. num_field, plain_field, mixed_field (and the spin fields) and opt_field take part. - Engine: undo groups (Session::begin_undo_group / end_undo_group). The edits made in a group, commands and committed live drags alike, are one undo step, journaled one by one; a cancelled group is undone and dropped from the journal. The app opens one while a label is dragged, so a scrub is one undo step whichever path the panel applies values by (app.run, session.execute, live_run), and Escape cancels it (shortcuts leave Escape to the drag, so it doesn't close a dialog or deselect). - Preferences > General > Scrub Numeric Fields by Dragging (`scrubNumericFields`, on by default), translated in ja, es, zh-hans, zh-hant and pt-br. - Tests: label drags with Shift/Ctrl, limits, counts and units, Escape, the preference, the cursor, click-to-focus, no scrub on the box or without a label, and in the app one undo step for a W drag. - ROADMAP and docs/mcp.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>