DrawToolsRedux/DrawPolygon.cs
(开头部分) 7KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Globalization;
using System.Runtime.Serialization;
using System.Windows.Forms;
namespace DrawTools
{
/// <summary>
/// Polygon graphic object
/// </summary>
//[Serializable]
public class DrawPolygon : DrawLine
{
private ArrayList pointArray; // list of points
private Cursor handleCursor;
private const string entryLength = "Length";
private const string entryPoint = "Point";
public DrawPolygon()
{
pointArray = new ArrayList();
LoadCursor();
Initialize();
}
public DrawPolygon(int x1, int y1, int x2, int y2)
{
pointArray = new ArrayList();
pointArray.Add(new Point(x1, y1));
pointArray.Add(new Point(x2, y2));
LoadCursor();
Initialize();
}
public DrawPolygon(int x1, int y1, int x2, int y2, DrawingPens.PenType p)
{
pointArray = new ArrayList();
pointArray.Add(new Point(x1, y1));
pointArray.Add(new Point(x2, y2));
DrawPen = DrawingPens.SetCurrentPen(p);
PenType = p;
LoadCursor();
Initialize();
}
public DrawPolygon(int x1, int y1, int x2, int y2, Color lineColor, int lineWidth)
{
pointArray = new ArrayList();
pointArray.Add(new Point(x1, y1));
pointArray.Add(new Point(x2, y2));
Color = lineColor;
PenWidth = lineWidth;
后面还有 222 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。