資源簡介
WINFORM 繪制流程圖 開源 .net開源的矢量圖、流程圖這繪制軟件,對學習.Net項目中的MVC架構、C#編程、GDI+圖像處理、實現應用程序的撤消與重做等其他很多知識都有很好的幫助。
代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.Text;
using?System.Drawing;
using?Netron.Diagramming.Core;
using?System.Drawing.Drawing2D;
using?System.Runtime.Serialization;
namespace?BasicShapes
{
????[Serializable()]
????[Shape(
????????“Triangle“?//?Shape?Name
????????“5B148C27-31F4-456f-8D1F-C7B8C8E86283“??//?Shape?Key
????????“Basic?Shapes“??//?Category
????????“A?triangular?shape.“??//?Description
????????false)]??//?Is?for?internal?use?only???NO.
????public?class?TriangleShape?:?SimpleShapebase
????{
????????#region?Fields
????????//?------------------------------------------------------------------
????????///?
????????///?The?current?version?-?used?when?deserializing?the?shape.
????????///?
????????//?------------------------------------------------------------------
????????protected?double?triangleShapeVersion?=?1.0;
????????#endregion
????????#region?Properties
????????//?------------------------------------------------------------------
????????///?
????????///?Gets?the?graphics?path?that?defines?this?triangle.
????????///?
????????//?------------------------------------------------------------------
????????public?GraphicsPath?Path
????????{
????????????get
????????????{
????????????????GraphicsPath?path?=?new?GraphicsPath();
????????????????path.AddLine(TopCenter
????????????????????BottomRightCorner);
????????????????path.AddLine(BottomRightCorner
????????????????????BottomLeftCorner);
????????????????path.AddLine(BottomLeftCorner
????????????????????TopCenter);
????????????????return?path;
????????????}
????????}
????????//?------------------------------------------------------------------
????????///?
????????///?Gets?the?friendly?name?of?this?shape.
????????///?
????????//?------------------------------------------------------------------
????????public?override?string?EntityName
????????{
????????????get
????????????{
????????????????return?“三角形“;
????????????}
????????}
????????//?------------------------------------------------------------------
????????///?
????????///?Returns?the?version?of?this?shape.
????????///?
????????//?------------------------------------------------------------------
????????public?override?double?Version
????????{
????????????get
????????????{
????????????????return?triangleShapeVersion;
????????????}
????????}
????????#endregion
????????#region?Constructors
????????//?------------------------------------------------------------------
????????///?
????????///?Default?constructor.
????????///?
????????//?------------------------------------------------------------------
????????public?TriangleShape()
????????????:?base()
????????{
????????}
????????//?------------------------------------------------------------------
????????///?
????????///?Constructor?that?receives
評論
共有 條評論