示例#1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:Dt.Cells.Data.GcReportContext" /> class.
 /// </summary>
 /// <param name="report">The report.</param>
 /// <param name="dpi">The dpi.</param>
 public GcReportContext(GcReport report, int dpi)
 {
     this.upi        = 0x48;
     this.pages      = new List <List <GcPageBlock> >();
     this.pageRects  = new GcPageRectangles();
     this.measure    = new Utilities.MeasureUtility(UnitType.CentileInch, defaultFont);
     this.pageFooter = null;
     this.pageHeader = null;
     this.report     = report;
     this.dpi        = dpi;
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:Dt.Cells.Data.GcPageRectangles" /> class.
 /// </summary>
 /// <param name="rects">The rectangles.</param>
 public GcPageRectangles(GcPageRectangles rects)
 {
     this.contentRectangle    = Windows.Foundation.Rect.Empty;
     this.cropRectangle       = Windows.Foundation.Rect.Empty;
     this.pageHeaderRectangle = Windows.Foundation.Rect.Empty;
     this.pageFooterRectangle = Windows.Foundation.Rect.Empty;
     this.pageRectangle       = Windows.Foundation.Rect.Empty;
     this.cropRectangle       = rects.cropRectangle;
     this.contentRectangle    = rects.contentRectangle;
     this.pageHeaderRectangle = rects.pageHeaderRectangle;
     this.pageFooterRectangle = rects.pageFooterRectangle;
 }
示例#3
0
        /// <summary>
        /// Creates the new page.
        /// </summary>
        /// <returns></returns>
        public GcPageBlock CreateNewPage()
        {
            GcPageBlock block = new GcPageBlock();

            Windows.Foundation.Size pageSize = Utilities.GetPageSize(this.Report.PaperSize, this.Report.Orientation);
            block.X      = 0.0;
            block.Y      = 0.0;
            block.Width  = pageSize.Width;
            block.Height = pageSize.Height;
            GcPageRectangles rectangles = new GcPageRectangles {
                CropRectangle = this.pageRects.CropRectangle
            };

            block.Rectangles = rectangles;
            return(block);
        }