Java com.itextpdf.text.pdf PdfPTable fields, constructors, methods, implement or subclass

Example usage for Java com.itextpdf.text.pdf PdfPTable fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for com.itextpdf.text.pdf PdfPTable.

The text is from its open source code.

Subclass

com.itextpdf.text.pdf.PdfPTable has subclasses.
Click this link to see all its subclasses.

Field

intBASECANVAS
The index of the original PdfcontentByte.
intBACKGROUNDCANVAS
The index of the duplicate PdfContentByte where the background will be drawn.
intLINECANVAS
The index of the duplicate PdfContentByte where the border lines will be drawn.
intTEXTCANVAS
The index of the duplicate PdfContentByte where the text will be drawn.

Constructor

PdfPTable(final float relativeWidths[])
Constructs a PdfPTable with the relative column widths.
PdfPTable(final int numColumns)
Constructs a PdfPTable with numColumns columns.
PdfPTable(final PdfPTable table)
Constructs a copy of a PdfPTable.

Method

PdfPCelladdCell(final PdfPCell cell)
Adds a cell element.
voidaddCell(final String text)
Adds a cell element.
voidaddCell(final PdfPTable table)
Adds a nested table.
voidaddCell(final Image image)
Adds an Image as Cell.
voidaddCell(final Phrase phrase)
Adds a cell element.
PdfContentByte[]beginWritingRows(final PdfContentByte canvas)
Gets and initializes the 4 layers where the table is written to.
floatcalculateHeights()
Calculates the heights of the table.
voidcompleteRow()
Completes the current row with the default cell.
voidendWritingRows(final PdfContentByte[] canvases)
Finishes writing the table.
float[]getAbsoluteWidths()
Gets the absolute sizes of each column width.
ListgetChunks()
Gets all the chunks in this element.
PdfPCellgetDefaultCell()
Gets the default PdfPCell that will be used as reference for all the addCell methods except addCell(PdfPCell).
intgetFooterRows()
Gets the number of rows in the footer.
floatgetHeaderHeight()
Gets the height of the rows that constitute the header as defined by setHeaderRows().
intgetHeaderRows()
Gets the number of the rows that constitute the header.
intgetLastCompletedRowIndex()
Returns the index of the last completed row.
intgetNumberOfColumns()
Returns the number of columns.
PdfPRowgetRow(final int idx)
Gets a row with a given index.
floatgetRowHeight(final int idx)
Gets the height of a particular row.
ArrayListgetRows()
Gets an arraylist with all the rows in the table.
floatgetTotalHeight()
Gets the total height of the table.
floatgetTotalWidth()
Gets the full width of the table.
floatgetWidthPercentage()
Gets the width percentage that the table will occupy in the page.
voidkeepRowsTogether(int[] rows)
Defines which rows should not allow a page break (if possible).
voidkeepRowsTogether(int start)
Defines a range of rows (from the parameter to the last row) that should not allow a page break (if possible).
voidsetBreakPoints(int... breakPoints)
Defines where the table may be broken (if necessary).
voidsetComplete(final boolean complete)
voidsetExtendLastRow(final boolean extendLastRows, final boolean extendFinalRow)
When set the last row on every page will be extended to fill all the remaining space to the bottom boundary; except maybe the final row.
voidsetExtendLastRow(final boolean extendLastRows)
When set the last row on every page will be extended to fill all the remaining space to the bottom boundary.
voidsetFooterRows(int footerRows)
Sets the number of rows to be used for the footer.
voidsetHeaderRows(int headerRows)
Sets the number of the top rows that constitute the header.
voidsetHorizontalAlignment(final int horizontalAlignment)
Sets the horizontal alignment of the table relative to the page.
voidsetKeepTogether(final boolean keepTogether)
If true the table will be kept on one page if it fits, by forcing a new page if it doesn't fit on the current page.
voidsetLockedWidth(final boolean lockedWidth)
Uses the value in setTotalWidth() in Document.add().
voidsetPaddingTop(float paddingTop)
voidsetSpacingAfter(final float spacing)
Sets the spacing after this table.
voidsetSpacingBefore(final float spacing)
Sets the spacing before this table.
voidsetSplitRows(final boolean splitRows)
When set the rows that won't fit in the page will be split.
voidsetTableEvent(final PdfPTableEvent event)
Sets the table event for this table.
voidsetTotalWidth(final float totalWidth)
Sets the full width of the table.
voidsetTotalWidth(final float columnWidth[])
Sets the full width of the table from the absolute column width.
voidsetWidthPercentage(final float widthPercentage)
Sets the width percentage that the table will occupy in the page.
voidsetWidthPercentage(final float columnWidth[], final Rectangle pageSize)
Sets the percentage width of the table from the absolute column width.
voidsetWidths(final float relativeWidths[])
Sets the relative widths of the table.
voidsetWidths(final int relativeWidths[])
Sets the relative widths of the table.
intsize()
Gets the number of rows in this table.
floatwriteSelectedRows(final int rowStart, final int rowEnd, final float xPos, final float yPos, final PdfContentByte[] canvases)
Writes the selected rows to the document.
floatwriteSelectedRows(final int rowStart, final int rowEnd, final float xPos, final float yPos, final PdfContentByte canvas)
Writes the selected rows to the document.