Vector Tool Requirements
Vector Tool Requirements
Here I will sum up all the requirements we gathered during the sprint
Vector System Requirements
General
- Krita reads SVG xml manually using SvgParser class created by Jan.
- Krita writes SVG xml data manually in the shapes themselves.
- [POSTPONED] Transformations and styling options can be inherited (as per SVG). Therefore the GUI should have an option for inherited state
- Krita support SVG 1.1 to some extent.
- [POSTPONED] (2-nd priority) Krita saves object styles as CSS style sheets inside SVG itself.
- Backward compatibility with older Krita vector object is not expected.
GUI Requirements
General
- In every vector tool the user should be able to select/switch the shapes
- Selection tool shows Gradient handles, when fill/stroke selection tab is active
- Shape editing tool doesn't show any gradient editing handles. Only real shape nodes.
Selection Tool
- Vector tools are renamed
- Shape Manipulations Tool -> Selection Tool (also called "Selection Mode")
- Path Editing Tool -> Editing Tool (also called "Editing Mode")
- Switching between Selection Mode and Edit Mode should work in both directions with:
- Pressing Enter
- Double-clicking
- Switching Selection Tool and Vector Editing Tool manually
- Pressing Ecs exits editing mode
- Vector Editing Tool (previously Path Editing Tool)
- Allows selecting objects
- Shown right next to the Selection Tool in the toolbox.
- Shape Properties docker should be merged into Tool Options docker
- [DISCARDED (we have only few shapes that support properties)] When multiple objects are selected, then shape properties should be combined.
- Selection modes
- Rubber-band drag selects depending on the dragging direction
- right-to-left --- cross-selection
- left-to-right --- bounding-selection
- the color of the rubber band changes depending on the direction/selection mode
- Shift+click toggles multiple selection
- Ctrl+click toggles overlapping objects
- Shift+drag *adds* objects to the current selection
- Shift+drag cannot remove the object from the current selection. Use Shift+click instead.
- Alt+drag allows you to start a rubber band without accidentally selecting and moving a shape
- Rubber-band drag selects depending on the dragging direction
- Alignment and Grouping
- Anignment options are moved into a separate docker
- They might also be available in the selection tool options as a popup menu
- [POSTPONED till text] If the current object is not text, buttons for baseline alignment are not visible.
- [POSTPONED] Transform tab
- Transform options change the current relative matrix of the object. That is, all the values are the relative coordinate system of the parent group.
- The options edit the matrix directly, not just combine new values with the existing matrix (like Inkscape does). That is, there is no Apply button: all the values are modified directly.
- The transformations are applied in the following order:
- Shear
- Scale
- Rotate
- Offset of the selected anchor point
- Geometry tab
- The user can always see the the size and offset of the bounding box of the object in a label. If it is possible, then changing the size, resizes of the shapes (that is stroke width is not changed). If there are multiple objects with non-uniform transformations are selected, then the objects are transformed, that is stroke width is affected.
- The user can force transformation instead of resizing by checking "Uniform scaling" checkbox.
- The bounding box is also painted on canvas when the object is selected.
- Scale, Rotate, and Transform actions done with the mouse work as usual (read: "like Transform Tool")
- Line Style
- Markers and Dash arrays are saved as separate XML/SVG files. So the user can create his own resources.
- Stroke color setting has the same widgets as the Fill one: None, [POSTPONED] Inherited, Gradient, Fill, [POSTPONED] Pattern.
- Selecting FG color with any color selector changes object fill to Solid+selected fg color
- Selecting BG color with any color selector changes object fill to Solid+selected bg color
- [POSTPONED] Color picker: Pressing some_key+click on any place of the document should select the fill of the object
[POSTPONED] Filter Tool
- Allows selecting objects
- The filter option are removed from Selection Tool and are edited by a special tool
- First Priority
- The Tool Options docker shows all predefined filers (preferably, with some preview)
- The user can select one of the predefined filters
- (Probably) he can also edit the main property of the filter, e.g. radius and the offset of the shadow filter.
- The filters can be imported from Inkskape and usual resources (including bundles). The Inkskape filters are just SVG files with 'defs' section that defines the filters.
- Second Priority
- Edit the filter using some special GUI. The GUIs in Inkscape and Karbon are extremely complicated. Invent something more obvious.
Gradient Tool
- Integrated into the Selection tool
- Allow saving the shape's gradient (fill and/or stroke one) into the set of predefined gradients in Krita resources with custom name.
- All gradients work in relative mode: the gradient is transformed with the shape itself.
[POSTPONED] Pattern Tool
- Integrate into the Selection tool
- No support for pattern rotation. It was not chosen in the KS stretchgoals.
Undecided Questions
- Boolean Operations for shapes. Should they be a tool? A menu action? Context menu? Or something else?
- How stroke/fill/filter properties are handled during the op? E.g. if we combine two shapes with different stroke properties using OR operation, what should be the stroke/fill of the final shape? The most sane approach would be to adopt the stroke/fill of the first selected shape. Or let the user choose.
- Last Author
- dkazakov
- Projects
- None
- Subscribers
- None