* add function to calculate if a subpath is inside polygon
* make is_subpath_inside_polygon() flexible
* obtimize is_subpath_inside_polygon function
* move is_inside_subpath function to Subpath struct method
* add interactive demo for subpath insideness
* Code review
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Make progress in text tool
* Add line_width to gcore and gstd
* minor fix
* Dragging sets line_width correctly
* Get draw overlay to work
* Typo fix
* Make progress in text tool
* Add line_width to gcore and gstd
* minor fix
* Dragging sets line_width correctly
* Get draw overlay to work
* Typo fix
* Improve text bounding box
* Add toggle for editing line width
* Take absolute value of drag
* Fix optional properties
* Code review
* Attempt to add box height and abort with keys
* Attempt to add key modifiers and snap manager
* Use resize for improved dragging
* Refactor typesetting configuration into a struct
* Fix missing px unit in frontend
* Remove lines on rendered text
* Fix backwards compatibility
* Refactor lenient slection as an associate function in tool data
* Add dashed quad to text nodes
* Use correct names for max height and width
* Additional renames and reorder
* ReResolve conflict
* Code review and improvements
---------
Co-authored-by: hypercube <0hypercube@gmail.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* properties panel remains active when user edits text layer
* Keep text layers selected after editing
* Update editor/src/messages/portfolio/document/document_message_handler.rs
* Delete Empty Text Layer on Escape or Right Click
* Fix: delete empty text layer on right click
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* added snap and lock angle to path tool
* fixed breakage of `tab` and `space` functionality
- Previous implementation broke functionality of using Tab to swap the being-dragged handle to its opposing handle, Now fixed.
- Previous implementation broke functionality of using space to drag the manipulator group (anchor + handles) while dragging a handle, Now fixed.
* fixed the angle snapping and locking when used together
Now, if `shift` is used to snap to a 15° increment, then `ctrl` is used to preserve the angle, releasing the `shift` key will still preserve the angle.
* Fix snapping angle logic
* Improve transforms
* added functionality for `alt` key
Now, temporarily converts selected handles to colinear if they are not already colinear.
* Revert "added functionality for `alt` key"
This reverts commit f12ba6fdbf261291ced0e042a2dfe12cddd2f9e8.
* Code review
---------
Co-authored-by: hypercube <0hypercube@gmail.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Fix text selection
* Remove old implementation
* minor change
* Use inbuilt function instead of helper
* Code review
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Tidy up number text alignment and decimal precision for quick measurement overlays
* Formatting changes
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Implement deselect on single-click and select all anchors on double-click
* fixed the single_click_behaviour
* fix flipSmoothSharp when doubleclick and drag
* Cleanup and Clippy fixes
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* setup single edge crossing handling for quick measure tool
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects.
* setup single edge crossing handling for quick measure tool
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects. Add a dashed_line_with_pattern function that gives more granular control over dash_width and gap_width.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects. Add a dashed_line_with_pattern function that gives more granular control over dash_width and gap_width.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects. Add a dashed_line_with_pattern function that gives more granular control over dash_width and gap_width.
* Setup quick measure functionality for intersecting objects and handle centerline cases for non intersecting objects. Add a dashed_line_with_pattern function that gives more granular control over dash_width and gap_width.
* Nit picks
* Define wrapper for Overlay_context line method
* Comments and consolidating lines of code
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* place new layer from basic tools within an artboard bounds
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
* add for Text Tool
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
* use click_xray function
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
* support for freehand tool
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
* support spline tool
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
---------
Signed-off-by: James Ryans <james.ryans2012@gmail.com>
* Selection history when creating a new layer
* fixed selection history
* cleaned up the code, removed duplicate network_metadata calls
* re: fixed selection history
Added a default value for selection_undo_history to make sure its never actually empty.