mirror of
https://github.com/penpot/penpot.git
synced 2025-01-10 17:00:36 -05:00
Add align to text and circle resize.
This commit is contained in:
parent
f054233a9e
commit
a63c9f7d33
1 changed files with 8 additions and 1 deletions
|
@ -141,12 +141,15 @@
|
|||
;; --- Vertex Access
|
||||
|
||||
(declare get-rect-vertext-point)
|
||||
(declare get-circle-vertext-point)
|
||||
|
||||
(defn get-vertex-point
|
||||
[shape id]
|
||||
(case (:type shape)
|
||||
:icon (get-rect-vertext-point shape id)
|
||||
:rect (get-rect-vertext-point shape id)))
|
||||
:rect (get-rect-vertext-point shape id)
|
||||
:circle (get-circle-vertext-point shape id)
|
||||
:text (get-rect-vertext-point shape id)))
|
||||
|
||||
(defn- get-rect-vertext-point
|
||||
[{:keys [x1 y1 x2 y2]} id]
|
||||
|
@ -156,6 +159,10 @@
|
|||
3 (gpt/point x1 y2)
|
||||
4 (gpt/point x2 y2)))
|
||||
|
||||
(defn- get-circle-vertext-point
|
||||
[{:keys [rx ry]} id]
|
||||
(gpt/point rx ry))
|
||||
|
||||
;; --- Vertex Movement (Relative)
|
||||
|
||||
(declare move-rect-vertex)
|
||||
|
|
Loading…
Reference in a new issue