From 57199edb8fb33fa335a1cf1d8aca60a2d9abe5ee Mon Sep 17 00:00:00 2001 From: Roman Bruckner Date: Fri, 17 Jun 2022 12:29:58 +0200 Subject: [PATCH] attributes: use cached segments subdivisions for calculating the connection stubs (#1702) --- src/dia/attributes/index.mjs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/dia/attributes/index.mjs b/src/dia/attributes/index.mjs index 4fc905e60..dcffd388b 100644 --- a/src/dia/attributes/index.mjs +++ b/src/dia/attributes/index.mjs @@ -620,8 +620,9 @@ const attributesNS = { offset = stubs; } const path = this.getConnection(); - const sourceParts = path.divideAtLength(offset); - const targetParts = path.divideAtLength(-offset); + const segmentSubdivisions = this.getConnectionSubdivisions(); + const sourceParts = path.divideAtLength(offset, { segmentSubdivisions }); + const targetParts = path.divideAtLength(-offset, { segmentSubdivisions }); if (sourceParts && targetParts) { d = `${sourceParts[0].serialize()} ${targetParts[1].serialize()}`; }