Example #1
0
 public DrawPencil(int x1, int y1, int x2, int y2, Color lineColor, int lineWidth, TypeOfPen.PenType p)
 {
     pointArray = new ArrayList();
     pointArray.Add(new Point(x1, y1));
     pointArray.Add(new Point(x2, y2));
     PenType  = p;
     Color    = lineColor;
     PenWidth = lineWidth;
     DrawPen  = TypeOfPen.SetCurrentPen(PenType, Color, PenWidth);
     LoadCursor();
     Initialize();
 }
Example #2
0
 public DrawLine(int x1, int y1, int x2, int y2, Color lineColor, int lineWidth, TypeOfPen.PenType p)
 {
     startPoint.X = x1;
     startPoint.Y = y1;
     endPoint.X   = x2;
     endPoint.Y   = y2;
     Color        = lineColor;
     PenWidth     = lineWidth;
     PenType      = p;
     DrawPen      = TypeOfPen.SetCurrentPen(PenType, Color, PenWidth);
     ZOrder       = 0;
     Initialize();
 }
Example #3
0
 public DrawEllipse(int x, int y, int width, int height, Color lineColor, int lineWidth, TypeOfPen.PenType pType, Color fillColor, Image fillImage, bool filled, bool gradient, bool hatch, bool texture)
 {
     Rectangle = new Rectangle(x, y, width, height);
     Center    = new Point(x + (width / 2), y + (height / 2));
     PenType   = pType;
     Color     = lineColor;
     PenWidth  = lineWidth;
     PenType   = pType;
     DrawPen   = TypeOfPen.SetCurrentPen(PenType, Color, PenWidth);
     FillColor = fillColor;
     FillImage = fillImage;
     Filled    = filled;
     Gradient  = gradient;
     Hatch     = hatch;
     Texture   = texture;
     Initialize();
 }
Example #4
0
 public DrawRectangle(int x, int y, int width, int height, Color lineColor, int lineWidth, TypeOfPen.PenType pType, Color fillColor, Image fillImage, bool filled, bool gradient, bool hatch, bool texture)
 {
     Center           = new Point(x + (width / 2), y + (height / 2));
     rectangle.X      = x;
     rectangle.Y      = y;
     rectangle.Width  = width;
     rectangle.Height = height;
     PenType          = pType;
     Color            = lineColor;
     PenWidth         = lineWidth;
     DrawPen          = TypeOfPen.SetCurrentPen(PenType, Color, PenWidth);
     FillColor        = fillColor;
     FillImage        = fillImage;
     Gradient         = gradient;
     Filled           = filled;
     Hatch            = hatch;
     Texture          = texture;
 }