Ejemplo n.º 1
0
 //draw shape method
 public void DrawShape(IGraphics graphics)
 {
     DoDrawShape(graphics);
     if (IsSelected)
     {
         graphics.DrawBorder(TopLeftPoint, BottomRightPoint);
     }
 }
Ejemplo n.º 2
0
 //draw Shapes
 public void DrawShapes(IGraphics graphics)
 {
     graphics.ClearCanvas();
     foreach (Shape shape in Shapes)
     {
         shape.DrawShape(graphics);
     }
     if (operationShape != null)
     {
         operationShape.DrawShape(graphics);
     }
 }
Ejemplo n.º 3
0
 //a virutal function to draw shape
 protected virtual void DoDrawShape(IGraphics graphics)
 {
 }
Ejemplo n.º 4
0
 //draw all shapes
 public void DrawShapes(IGraphics graphics)
 {
     PaintModel.DrawShapes(graphics);
 }
Ejemplo n.º 5
0
 //rectangle draw
 protected override void DoDrawShape(IGraphics graphics)
 {
     graphics.DrawRectangle(TopLeftPoint, BottomRightPoint);
 }