Ejemplo n.º 1
0
        public static void AddShapeToGraphicsPath(
            GraphicsPath path,
            ISegment2DIterator iterator,
            bool connect)
        {
            GeneralShape2D generalShape2D = new GeneralShape2D(iterator, true);

            path.AddPath((GraphicsPath)generalShape2D, connect);
        }
Ejemplo n.º 2
0
        private FlatShape4D method_0(Matrix4D transform, Matrix4D inverse)
        {
            GeneralShape2D generalShape2D = new GeneralShape2D();

            foreach (Polyline4D polyline4D in (IEnumerable <Polyline4D>) this.ilist_0)
            {
                Polyline2D polyline2D = new Polyline2D(polyline4D.Closed);
                foreach (Vector4D point in (List <Vector4D>)polyline4D)
                {
                    polyline2D.Add(inverse.TransformTo2D(point));
                }
                generalShape2D.Append((IShape2D)polyline2D, false);
            }
            return(new FlatShape4D((IShape2D)generalShape2D, transform, this.IsFilled));
        }
Ejemplo n.º 3
0
 private GeneralShape2D(GeneralShape2D baseShape, int sStart, int sEnd, int pStart, int pEnd)
 {
     this.int_2     = pEnd - pStart;
     this.point2D_0 = new Point2D[this.int_2];
     Array.Copy((Array)baseShape.point2D_0, pStart, (Array)this.point2D_0, 0, this.int_2);
     this.int_3         = sEnd - sStart;
     this.segmentType_0 = new SegmentType[this.int_3];
     Array.Copy((Array)baseShape.segmentType_0, sStart, (Array)this.segmentType_0, 0, this.int_3);
     this.bool_0 = true;
     if (baseShape.int_4 <= 0)
     {
         return;
     }
     foreach (SegmentType segmentType in this.segmentType_0)
     {
         if (segmentType == SegmentType.QuadTo)
         {
             ++this.int_4;
         }
     }
 }