From 85d7f6c8ff43e2680795c3748b7bc7cf2a755789 Mon Sep 17 00:00:00 2001 From: unanmed <1319491857@qq.com> Date: Sat, 30 Nov 2024 23:30:23 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20graphics=20=E8=AF=A6=E7=BB=86=E6=9C=9F?= =?UTF-8?q?=E6=9C=9B=E7=BB=93=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/render/preset/graphics.ts | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/core/render/preset/graphics.ts b/src/core/render/preset/graphics.ts index 997e881..c863e3e 100644 --- a/src/core/render/preset/graphics.ts +++ b/src/core/render/preset/graphics.ts @@ -3,6 +3,16 @@ import { RenderItem } from '../item'; import { Transform } from '../transform'; import { ElementNamespace, ComponentInternalInstance } from 'vue'; +/* + * Expected usage (this comment needs to be deleted after implements correctly): + * + * + * + * + * + * Line BezierCurve QuadraticCurve 无法设置填充属性,如设置则无效 + */ + interface ILineProperty { /** 线宽 */ lineWidth: number; @@ -31,11 +41,13 @@ interface IGraphicProperty extends ILineProperty { export const enum GraphicMode { /** 仅填充 */ - Fill = 1, + Fill, /** 仅描边 */ - Stroke = 2, - /** 填充+描边 */ - All = 3 + Stroke, + /** 先填充,然后描边 */ + FillAndStroke, + /** 先描边,然后填充 */ + StrokeAndFill } export abstract class GraphicItemBase