iTextSharp.text.pdf.PdfPRow.InitExtraHeights C# (CSharp) Метод

InitExtraHeights() защищенный Метод

protected InitExtraHeights ( ) : void
Результат void
        protected internal void InitExtraHeights()
        {
            extraHeights = new float[cells.Length];
            for (int i = 0; i < extraHeights.Length; i++) {
                extraHeights[i] = 0;
            }
        }

Usage Example

Пример #1
0
 /**
 * Calculates the extra height needed in a row because of rowspans.
 * @param    start   the index of the start row (the one to adjust)
 * @param    end     the index of the end row on the page
 * @since    2.1.6
 */
 protected PdfPRow AdjustCellsInRow(int start, int end) {
     PdfPRow row = new PdfPRow(GetRow(start));
     row.InitExtraHeights();
     PdfPCell cell;
     PdfPCell[] cells = row.GetCells();
     for (int i = 0; i < cells.Length; i++) {
         cell = cells[i];
         if (cell == null || cell.Rowspan == 1)
             continue;
         int stop = Math.Min(end, start + cell.Rowspan);
         float extra = 0;
         for (int k = start + 1; k < stop; k++) {
             extra += GetRowHeight(k);
         }
         row.SetExtraHeight(i, extra);
     }
     return row;
 }