mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-01 13:47:21 -06:00
People reuse the same gradients across documents and rebuilt them by hand. The Gradient panel now has a Presets menu: the presets of the app's built-in gradient libraries, grouped by library (theme), then the saved ones. Choosing one gives the gradient behind the active proxy (or a solid paint) the preset's type, stops, method and dither, keeping its placement, as one undo step, through paint.editGradient. The panel menu saves the current gradient as a preset (named in a dialog) and deletes saved ones; Hide/Show Presets toggles the row. Saved presets are kept with the preferences, next to the other user preset lists (width profiles, flattener, perspective). Stops linked to a document swatch keep their colour, unlinked, since a preset is used in other documents. Built-in presets can't be deleted; names are unique. Commands: gradient.presets.list, .apply, .save and .delete. The menu's rows are drawn only while in view, as its headings are. Tests: engine tests for list, apply (fill and stroke, placement kept, one undo step), save (unique names, unlinked swatch stops) and delete; panel tests for applying from the menu and saving, deleting and hiding presets from the panel menu, including scrolling the menu to the saved presets. Docs: gaps G13, target-app and UI parity, ROADMAP.