Java Code Examples for com.lowagie.text.Table#complete()

The following examples show how to use com.lowagie.text.Table#complete() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: PdfTable.java    From gcs with Mozilla Public License 2.0 6 votes vote down vote up
/**
 * Constructs a <CODE>PdfTable</CODE>-object.
 *
 * @param table a <CODE>Table</CODE>
 * @param left the left border on the page
 * @param right the right border on the page
 * @param top the start position of the top of the table
 * @since a parameter of this method has been removed in iText 2.0.8
 */

PdfTable(Table table, float left, float right, float top) {
	// constructs a Rectangle (the bottom value will be changed afterwards)
	super(left, top, right, top);
	this.table = table;
	table.complete();

	// copying the attributes from class Table
	cloneNonPositionParameters(table);

	columns = table.getColumns();
	positions = table.getWidths(left, right - left);

	// initialization of some parameters
	setLeft(positions[0]);
	setRight(positions[positions.length - 1]);

	headercells = new ArrayList();
	cells = new ArrayList();

	updateRowAdditionsInternal();
}
 
Example 2
Source File: PdfTable.java    From itext2 with GNU Lesser General Public License v3.0 6 votes vote down vote up
/**
 * Constructs a <CODE>PdfTable</CODE>-object.
 *
 * @param	table	a <CODE>Table</CODE>
 * @param	left	the left border on the page
 * @param	right	the right border on the page
 * @param	top		the start position of the top of the table
 * @since	a parameter of this method has been removed in iText 2.0.8
 */
   
PdfTable(Table table, float left, float right, float top) {
	// constructs a Rectangle (the bottom value will be changed afterwards)
	super(left, top, right, top);
	this.table = table;
       table.complete();
       
	// copying the attributes from class Table
       cloneNonPositionParameters(table);

	this.columns = table.getColumns();
	positions = table.getWidths(left, right - left);
       
	// initialization of some parameters
	setLeft(positions[0]);
	setRight(positions[positions.length - 1]);
	
	headercells = new ArrayList();
	cells = new ArrayList();

	updateRowAdditionsInternal();
}
 
Example 3
Source File: PdfTable.java    From MesquiteCore with GNU Lesser General Public License v3.0 6 votes vote down vote up
/**
 * Constructs a <CODE>PdfTable</CODE>-object.
 *
 * @param	table	a <CODE>Table</CODE>
 * @param	left	the left border on the page
 * @param	right	the right border on the page
 * @param	top		the start position of the top of the table
 * @param	supportUpdateRowAdditions	
 * 					if true, table rows will be deleted after building the PdfTable table, 
 * 					in order to preserve memory and detect future row additions
 */
   
PdfTable(Table table, float left, float right, float top, boolean supportUpdateRowAdditions) {
	// constructs a Rectangle (the bottomvalue will be changed afterwards)
	super(left, top, right, top);
	this.table = table;
       table.complete();

	// copying the attributes from class Table
       cloneNonPositionParameters(table);

	this.columns = table.columns();
	positions = table.getWidths(left, right - left);
       
	// initialisation of some parameters
	setLeft(positions[0]);
	setRight(positions[positions.length - 1]);
	
	headercells = new ArrayList();
	cells = new ArrayList();

	updateRowAdditionsInternal();
	if (supportUpdateRowAdditions) {
		table.deleteAllRows();
	}
}
 
Example 4
Source File: RtfTable.java    From itext2 with GNU Lesser General Public License v3.0 2 votes vote down vote up
/**
 * Constructs a RtfTable based on a Table for a RtfDocument.
 * 
 * @param doc The RtfDocument this RtfTable belongs to
 * @param table The Table that this RtfTable wraps
 */
public RtfTable(RtfDocument doc, Table table) {
    super(doc);
    table.complete();
    importTable(table);
}
 
Example 5
Source File: PatchRtfTable.java    From pentaho-reporting with GNU Lesser General Public License v2.1 2 votes vote down vote up
/**
 * Constructs a PatchRtfTable based on a Table for a RtfDocument.
 *
 * @param doc
 *          The RtfDocument this PatchRtfTable belongs to
 * @param table
 *          The Table that this PatchRtfTable wraps
 */
public PatchRtfTable( RtfDocument doc, Table table ) {
  super( doc );
  table.complete();
  importTable( table );
}