Beispiel #1
0
 public void Draw(Graphics graphics)
 {
     using (var pen = PenBillet.CreatePen())
     {
         graphics.DrawCurve(pen, points_);
     }
 }
Beispiel #2
0
 public RectangleShape(Point upperLeftCorner, Point lowerRightCorner, PenBillet billet)
 {
     upperLeftCorner_ = upperLeftCorner;
     penBillet_       = billet;
     width_           = lowerRightCorner.X - upperLeftCorner.X;
     height_          = lowerRightCorner.Y - upperLeftCorner.Y;
 }
Beispiel #3
0
 /// <summary>
 /// Creates an arc shape.
 /// </summary>
 /// <param name="rect">Bounding rectangle of the ellipse the arc belongs to.</param>
 /// <param name="startAngle"></param>
 /// <param name="sweepAngle"></param>
 /// <param name="penBillet"></param>
 public ArcShape(Rectangle rect, float startAngle, float sweepAngle, PenBillet penBillet)
 {
     rect_       = rect;
     startAngle_ = startAngle;
     sweepAngle_ = sweepAngle;
     penBillet_  = penBillet;
 }
Beispiel #4
0
 public CurveShape(IEnumerable <Point> points, PenBillet billet)
 {
     penBillet_ = billet;
     points_    = points.ToArray();
 }
Beispiel #5
0
 public LineShape(Point start, Point end, PenBillet billet)
 {
     start_     = start;
     end_       = end;
     penBillet_ = billet;
 }