From 5066a3d90ab19f8380dbb4159d57b0b8e3f17649 Mon Sep 17 00:00:00 2001 From: lixiaojun <1287241240@qq.com> Date: 星期四, 20 三月 2025 15:31:11 +0800 Subject: [PATCH] L3d基础功能完善 --- Yw.WinFrmUI.Hydro.L3d.Core/01-network/03-node/00-core/NodeL3d.cs | 38 +++++++++++++++++++++++++++----------- 1 files changed, 27 insertions(+), 11 deletions(-) diff --git a/Yw.WinFrmUI.Hydro.L3d.Core/01-network/03-node/00-core/NodeL3d.cs b/Yw.WinFrmUI.Hydro.L3d.Core/01-network/03-node/00-core/NodeL3d.cs index 489231b..0886486 100644 --- a/Yw.WinFrmUI.Hydro.L3d.Core/01-network/03-node/00-core/NodeL3d.cs +++ b/Yw.WinFrmUI.Hydro.L3d.Core/01-network/03-node/00-core/NodeL3d.cs @@ -1,4 +1,5 @@ -锘縩amespace Yw.WinFrmUI.Hydro +锘� +namespace Yw.WinFrmUI.Hydro { /// <summary> /// 鑺傜偣 @@ -8,7 +9,15 @@ /// <summary> /// /// </summary> - public NodeL3d() { } + public NodeL3d() + { + this.Style2d = new StyleNode2dL3d() + { + Normal = new StylePoint2dL3d(3f, Color.Red), + Hovered = new StylePoint2dL3d(6f, "#00BFFF"), + Selected = new StylePoint2dL3d(4f, "#008000") + }; + } /// <summary> /// @@ -16,6 +25,7 @@ public NodeL3d(NodeL3d rhs) : base(rhs) { this.Position = new PointL3d(rhs.Position); + this.Style2d = new StyleNode2dL3d(rhs.Style2d); } /// <summary> @@ -24,20 +34,26 @@ public PointL3d Position { get; set; } /// <summary> - /// + /// 2d鏍峰紡 /// </summary> - public override void Draw2d() + public StyleNode2dL3d Style2d { get; set; } + + /// <summary> + /// 鑾峰彇浣嶇疆 + /// </summary> + public override List<PointL3d> GetPositions() { - switch (this.State) - { - case eVisualState.Normal: DrawPoint2dHelper.Draw(5f, Color.Red, this.Position); break; - case eVisualState.Hovered: DrawPoint2dHelper.Draw(6f, ColorTranslator.FromHtml("#00BFFF"), this.Position); break; - case eVisualState.Selected: DrawPoint2dHelper.Draw(7f, ColorTranslator.FromHtml("#008000"), this.Position); break; - default: break; - } + return new List<PointL3d>() { this.Position }; } + + + + + + + } } -- Gitblit v1.9.3