From c35f8ab82c57849269a09fbad9d54d5085065d22 Mon Sep 17 00:00:00 2001 From: Hufe921 Date: Sat, 16 Sep 2023 20:02:03 +0800 Subject: [PATCH] fix: draw text element letter space error #282 --- src/editor/core/draw/Draw.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/editor/core/draw/Draw.ts b/src/editor/core/draw/Draw.ts index e97a37f..90f7e22 100644 --- a/src/editor/core/draw/Draw.ts +++ b/src/editor/core/draw/Draw.ts @@ -1593,9 +1593,9 @@ export class Draw { this.blockParticle.render(pageNo, element, x, y) } else { this.textParticle.record(ctx, element, x, y + offsetY) - // 如果设置字宽需单独绘制 - if (element.width) { - this._drawRichText(ctx) + // 如果设置字宽、字间距需单独绘制 + if (element.width || element.letterSpacing) { + this.textParticle.complete() } } // 下划线记录