Ejemplo n.º 1
0
        public override void Draw(PixelFarm.Drawing.Painter p)
        {
            p.Clear(Drawing.Color.White);
            p.FillColor = Drawing.Color.Black;
            p.DrawRect(10, 10, 30, 30);

            foreach (var brushPath in this.myBrushPathList)
            {
                if (brushPath.Vxs != null)
                {
                    p.Fill(brushPath.Vxs);
                }
                else
                {
                    var contPoints = brushPath.contPoints;
                    int pcount     = contPoints.Count;
                    for (int i = 1; i < pcount; ++i)
                    {
                        var p0 = contPoints[i - 1];
                        var p1 = contPoints[i];
                        p.DrawLine(p0.x, p0.y, p1.x, p1.y);
                    }
                }
            }
        }