예제 #1
0
 public PathElement(float x, float y)
 {
     X = x;
       Y = y;
       m_Primitives = new List<PathPrimitive>();
       Style = new PdfDrawStyle();
 }
예제 #2
0
 public RectangleElement(float x1, float y1, float x2, float y2, PdfDrawStyle borderStyle)
 {
     X = x1;
       Y = y1;
       X1 = x2;
       Y1 = y2;
       Style = borderStyle;
 }
예제 #3
0
 public PathElement(float x, float y, PdfDrawStyle style)
     : this(x, y)
 {
     Style = style;
 }
예제 #4
0
파일: PdfPage.cs 프로젝트: itadapter/nfx
        /// <summary>
        /// Add rectangle primitive to the page
        /// </summary>
        public RectangleElement AddRectangle(float x1, float y1, float x2, float y2, PdfDrawStyle style)
        {
            var rectangle = new RectangleElement(x1, y1, x2, y2, style);
              Add(rectangle);

              return rectangle;
        }
예제 #5
0
파일: PdfPage.cs 프로젝트: itadapter/nfx
        /// <summary>
        /// Add path to the page
        /// </summary>
        public PathElement AddPath(float x, float y, PdfDrawStyle style)
        {
            var path = new PathElement(x, y, style);
              Add(path);

              return path;
        }
예제 #6
0
파일: PdfPage.cs 프로젝트: itadapter/nfx
        /// <summary>
        /// Add line primitive to the page
        /// </summary>
        public PathElement AddLine(float x1, float y1, float x2, float y2, PdfDrawStyle style)
        {
            var path = new PathElement(x1, y1, style);
              path.AddLine(x2, y2);
              Add(path);

              return path;
        }
예제 #7
0
파일: PdfPage.cs 프로젝트: itadapter/nfx
        /// <summary>
        /// Add circle primitive to the page
        /// </summary>
        public PathElement AddCircle(float centerX, float centerY, float r, PdfDrawStyle borderStyle)
        {
            var path = new PathElement(centerX - r, centerY, borderStyle);
              path.IsClosed = true;
              path.AddBezier(centerX - r, centerY + Constants.SQRT_TWO * r, centerX + r, centerY + Constants.SQRT_TWO * r, centerX + r, centerY);
              path.AddBezier(centerX + r, centerY - Constants.SQRT_TWO * r, centerX - r, centerY - Constants.SQRT_TWO * r, centerX - r, centerY);
              Add(path);

              return path;
        }