public abstract class Barcode2D extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static float |
DEFAULT_MODULE_SIZE |
| Constructor and Description |
|---|
Barcode2D() |
| Modifier and Type | Method and Description |
|---|---|
abstract com.itextpdf.kernel.pdf.xobject.PdfFormXObject |
createFormXObject(com.itextpdf.kernel.colors.Color foreground,
com.itextpdf.kernel.pdf.PdfDocument document)
Creates a PdfFormXObject with the barcode.
|
com.itextpdf.kernel.pdf.xobject.PdfFormXObject |
createFormXObject(com.itextpdf.kernel.pdf.PdfDocument document)
Creates a PdfFormXObject with the barcode.
|
abstract com.itextpdf.kernel.geom.Rectangle |
getBarcodeSize()
Gets the maximum area that the barcode and the text, if
any, will occupy.
|
abstract com.itextpdf.kernel.geom.Rectangle |
placeBarcode(com.itextpdf.kernel.pdf.canvas.PdfCanvas canvas,
com.itextpdf.kernel.colors.Color foreground)
Places the barcode in a
PdfCanvas. |
protected static final float DEFAULT_MODULE_SIZE
public abstract com.itextpdf.kernel.geom.Rectangle getBarcodeSize()
public abstract com.itextpdf.kernel.geom.Rectangle placeBarcode(com.itextpdf.kernel.pdf.canvas.PdfCanvas canvas,
com.itextpdf.kernel.colors.Color foreground)
PdfCanvas. The
barcode is always placed at coordinates (0, 0). Use the
translation matrix to move it elsewhere.canvas - the PdfCanvas where the barcode will be placedforeground - the foreground color. It can be nullpublic com.itextpdf.kernel.pdf.xobject.PdfFormXObject createFormXObject(com.itextpdf.kernel.pdf.PdfDocument document)
document - The documentpublic abstract com.itextpdf.kernel.pdf.xobject.PdfFormXObject createFormXObject(com.itextpdf.kernel.colors.Color foreground,
com.itextpdf.kernel.pdf.PdfDocument document)
foreground - The color of the pixels. It can be nulldocument - The documentCopyright © 1998–2019 iText Group NV. All rights reserved.