mirror of
https://github.com/penpot/penpot.git
synced 2026-09-07 20:49:37 +00:00
Add update-path-point function to geom ns.
This commit is contained in:
parent
63f6de930d
commit
a4f29d25e1
@ -245,6 +245,16 @@
|
|||||||
:bottom (assoc shape :ry (max 0 (+ (:ry shape) dy)))
|
:bottom (assoc shape :ry (max 0 (+ (:ry shape) dy)))
|
||||||
:left (assoc shape :rx (max 0 (+ (:rx shape) dx))))))
|
:left (assoc shape :rx (max 0 (+ (:rx shape) dx))))))
|
||||||
|
|
||||||
|
;; --- Paths
|
||||||
|
|
||||||
|
(defn update-path-point
|
||||||
|
"Update a concrete point in the path.
|
||||||
|
|
||||||
|
The point should exists before, this function
|
||||||
|
does not adds it automatically."
|
||||||
|
[shape index point]
|
||||||
|
(assoc-in shape [:points index] point))
|
||||||
|
|
||||||
;; --- Resize (Absolute)
|
;; --- Resize (Absolute)
|
||||||
|
|
||||||
(declare resize-rect)
|
(declare resize-rect)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user