From dec622600d4ae8db6df26d4df35ab83fa20ccd4f Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Thu, 22 Feb 2024 10:46:23 +0100 Subject: [PATCH] :bug: Fix incorrect selrect calcultation from shape path --- common/src/app/common/geom/shapes/path.cljc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/src/app/common/geom/shapes/path.cljc b/common/src/app/common/geom/shapes/path.cljc index d3a00953d2..941b3ffc2f 100644 --- a/common/src/app/common/geom/shapes/path.cljc +++ b/common/src/app/common/geom/shapes/path.cljc @@ -7,6 +7,7 @@ (ns app.common.geom.shapes.path (:require [app.common.data :as d] + [app.common.data.macros :as dm] [app.common.geom.matrix :as gmt] [app.common.geom.point :as gpt] [app.common.geom.rect :as grc] @@ -975,7 +976,7 @@ flip-y (gmt/scale (gpt/point 1 -1)) :always (gmt/multiply (:transform-inverse shape (gmt/matrix)))) - center (or (gco/shape->center shape) + center (or (some-> (dm/get-prop shape :selrect) grc/rect->center) (content-center content)) base-content (transform-content