Tabnine Logo
PdfCell.cellpadding
Code IndexAdd Tabnine to your IDE (free)

How to use
cellpadding
method
in
com.lowagie.text.pdf.PdfCell

Best Java code snippets using com.lowagie.text.pdf.PdfCell.cellpadding (Showing top 6 results out of 315)

origin: fr.opensagres.xdocreport.itext-gae/itext-gae

/**
 * Sets the bottom of the Rectangle and determines the proper {link #verticalOffset}
 * to appropriately align the contents vertically.
 * @param value
 */
public void setBottom(float value) {
  super.setBottom(value);
  float firstLineRealHeight = firstLineRealHeight();
  float totalHeight = ury - value; // can't use top (already compensates for cellspacing)
  float nonContentHeight = (cellpadding() * 2f) + (cellspacing() * 2f);
  nonContentHeight += getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
  float interiorHeight = totalHeight - nonContentHeight;
  float extraHeight = 0.0f;
  switch (verticalAlignment) {
    case Element.ALIGN_BOTTOM:
      extraHeight = interiorHeight - contentHeight;
      break;
    case Element.ALIGN_MIDDLE:
      extraHeight = (interiorHeight - contentHeight) / 2.0f;
      break;
    default:    // ALIGN_TOP
      extraHeight = 0f;
  }
  extraHeight += cellpadding() + cellspacing();
  extraHeight += getBorderWidthInside(TOP);
  if (firstLine != null) {
    firstLine.height = firstLineRealHeight + extraHeight;
  }
}
origin: com.github.librepdf/openpdf

/**
 * Sets the bottom of the Rectangle and determines the proper {link #verticalOffset}
 * to appropriately align the contents vertically.
 * @param value
 */
public void setBottom(float value) {
  super.setBottom(value);
  float firstLineRealHeight = firstLineRealHeight();
  float totalHeight = ury - value; // can't use top (already compensates for cellspacing)
  float nonContentHeight = (cellpadding() * 2f) + (cellspacing() * 2f);
  nonContentHeight += getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
  float interiorHeight = totalHeight - nonContentHeight;
  float extraHeight = 0.0f;
  switch (verticalAlignment) {
    case Element.ALIGN_BOTTOM:
      extraHeight = interiorHeight - contentHeight;
      break;
    case Element.ALIGN_MIDDLE:
      extraHeight = (interiorHeight - contentHeight) / 2.0f;
      break;
    default:    // ALIGN_TOP
      extraHeight = 0f;
  }
  extraHeight += cellpadding() + cellspacing();
  extraHeight += getBorderWidthInside(TOP);
  if (firstLine != null) {
    firstLine.height = firstLineRealHeight + extraHeight;
  }
}
origin: es.gob.afirma/afirma-crypto-pdf-itext

/**
 * Sets the bottom of the Rectangle and determines the proper {link #verticalOffset}
 * to appropriately align the contents vertically.
 * @param value
 */
public void setBottom(float value) {
  super.setBottom(value);
  float firstLineRealHeight = firstLineRealHeight();
  float totalHeight = ury - value; // can't use top (already compensates for cellspacing)
  float nonContentHeight = (cellpadding() * 2f) + (cellspacing() * 2f);
  nonContentHeight += getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
  float interiorHeight = totalHeight - nonContentHeight;
  float extraHeight = 0.0f;
  switch (verticalAlignment) {
    case Element.ALIGN_BOTTOM:
      extraHeight = interiorHeight - contentHeight;
      break;
    case Element.ALIGN_MIDDLE:
      extraHeight = (interiorHeight - contentHeight) / 2.0f;
      break;
    default:    // ALIGN_TOP
      extraHeight = 0f;
  }
  extraHeight += cellpadding() + cellspacing();
  extraHeight += getBorderWidthInside(TOP);
  if (firstLine != null) {
    firstLine.height = firstLineRealHeight + extraHeight;
  }
}
origin: es.gob.afirma/afirma-crypto-pdf-itext

float newBottom = top - contentHeight - (2f * cellpadding()) - (2f * cellspacing());
newBottom -= getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
setBottom(newBottom);
origin: fr.opensagres.xdocreport.itext-gae/itext-gae

float newBottom = top - contentHeight - (2f * cellpadding()) - (2f * cellspacing());
newBottom -= getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
setBottom(newBottom);
origin: com.github.librepdf/openpdf

float newBottom = top - contentHeight - (2f * cellpadding()) - (2f * cellspacing());
newBottom -= getBorderWidthInside(TOP) + getBorderWidthInside(BOTTOM);
setBottom(newBottom);
com.lowagie.text.pdfPdfCellcellpadding

Javadoc

This is the cellpadding of the cell.

Popular methods of PdfCell

  • <init>
    Constructs a PdfCell-object.
  • addImage
    Adds an image to this Cell.
  • addLine
  • addList
  • cellspacing
    Gets the cellspacing of a cell.
  • cloneNonPositionParameters
  • firstLineRealHeight
    Calculates what the height of the first line should be so that the content will be flush with the to
  • flushCurrentLine
  • getBorderWidthBottom
  • getBorderWidthInside
    Gets the amount of the border for the specified side that is inside the Rectangle. For non-variable
  • getBorderWidthLeft
  • getBorderWidthRight
  • getBorderWidthLeft,
  • getBorderWidthRight,
  • getBorderWidthTop,
  • getBottom,
  • getHeight,
  • getImages,
  • getLeft,
  • getLines,
  • getRight

Popular in Java

  • Reading from database using SQL prepared statement
  • compareTo (BigDecimal)
  • onRequestPermissionsResult (Fragment)
  • getSystemService (Context)
  • FileInputStream (java.io)
    An input stream that reads bytes from a file. File file = ...finally if (in != null) in.clos
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • PrintWriter (java.io)
    Wraps either an existing OutputStream or an existing Writerand provides convenience methods for prin
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now