HiraokaHyperTools.iTextSharp-LGPL  0.2.5
iTextSharp.text.pdf.BarcodeInter25 Class Reference
Inheritance diagram for iTextSharp.text.pdf.BarcodeInter25:
iTextSharp.text.pdf.Barcode

Public Member Functions

 BarcodeInter25 ()
 
override Rectangle PlaceBarcode (PdfContentByte cb, Color barColor, Color textColor)
 
override System.Drawing.Image CreateDrawingImage (System.Drawing.Color foreground, System.Drawing.Color background)
 
- Public Member Functions inherited from iTextSharp.text.pdf.Barcode
PdfTemplate CreateTemplateWithBarcode (PdfContentByte cb, Color barColor, Color textColor)
 
Image CreateImageWithBarcode (PdfContentByte cb, Color barColor, Color textColor)
 

Static Public Member Functions

static string KeepNumbers (string text)
 
static char GetChecksum (string text)
 
static byte[] GetBarsInter25 (string text)
 

Properties

override RectangleBarcodeSize [get]
 
- Properties inherited from iTextSharp.text.pdf.Barcode
float X [get, set]
 
float N [get, set]
 
BaseFont Font [get, set]
 
float Size [get, set]
 
float Baseline [get, set]
 
float BarHeight [get, set]
 
int TextAlignment [get, set]
 
bool GenerateChecksum [get, set]
 
bool ChecksumText [get, set]
 
bool StartStopText [get, set]
 
bool Extended [get, set]
 
virtual string Code [get, set]
 
bool GuardBars [get, set]
 
int CodeType [get, set]
 
abstract Rectangle BarcodeSize [get]
 
float InkSpreading [get, set]
 
String AltText [get, set]
 

Additional Inherited Members

- Static Public Attributes inherited from iTextSharp.text.pdf.Barcode
const int EAN13 = 1
 
const int EAN8 = 2
 
const int UPCA = 3
 
const int UPCE = 4
 
const int SUPP2 = 5
 
const int SUPP5 = 6
 
const int POSTNET = 7
 
const int PLANET = 8
 
const int CODE128 = 9
 
const int CODE128_UCC = 10
 
const int CODE128_RAW = 11
 
const int CODABAR = 12
 
- Protected Attributes inherited from iTextSharp.text.pdf.Barcode
float x
 
float n
 
BaseFont font
 
float size
 
float baseline
 
float barHeight
 
int textAlignment
 
bool generateChecksum
 
bool checksumText
 
bool startStopText
 
bool extended
 
string code = ""
 
bool guardBars
 
int codeType
 
float inkSpreading = 0
 
String altText
 

Detailed Description

Implements the code interleaved 2 of 5. The text can include non numeric characters that are printed but do not generate bars. The default parameters are:

*x = 0.8f;
*n = 2;
*font = BaseFont.CreateFont("Helvetica", "winansi", false);
*size = 8;
*baseline = size;
*barHeight = size * 3;
*textint= Element.ALIGN_CENTER;
*generateChecksum = false;
*checksumText = false;
  
Author
Paulo Soares (psoar.nosp@m.es@c.nosp@m.onsis.nosp@m.te.p.nosp@m.t)

Constructor & Destructor Documentation

◆ BarcodeInter25()

iTextSharp.text.pdf.BarcodeInter25.BarcodeInter25 ( )

Creates new BarcodeInter25

Member Function Documentation

◆ CreateDrawingImage()

override System.Drawing.Image iTextSharp.text.pdf.BarcodeInter25.CreateDrawingImage ( System.Drawing.Color  foreground,
System.Drawing.Color  background 
)
virtual

◆ GetBarsInter25()

static byte [] iTextSharp.text.pdf.BarcodeInter25.GetBarsInter25 ( string  text)
static

Creates the bars for the barcode.

Parameters
textthe text. It can contain non numeric characters
Returns
the barcode

◆ GetChecksum()

static char iTextSharp.text.pdf.BarcodeInter25.GetChecksum ( string  text)
static

Calculates the checksum.

Parameters
textthe numeric text
Returns
the checksum

◆ KeepNumbers()

static string iTextSharp.text.pdf.BarcodeInter25.KeepNumbers ( string  text)
static

Deletes all the non numeric characters from text.

Parameters
textthe text
Returns
a string with only numeric characters

◆ PlaceBarcode()

override Rectangle iTextSharp.text.pdf.BarcodeInter25.PlaceBarcode ( PdfContentByte  cb,
Color  barColor,
Color  textColor 
)
virtual

Places the barcode in a PdfContentByte. The barcode is always placed at coodinates (0, 0). Use the translation matrix to move it elsewhere.

The bars and text are written in the following colors:

barColor

textColor

Result

null

null

bars and text painted with current fill color

barColor

null

bars and text painted with barColor

null

textColor

bars painted with current color
text painted with textColor

barColor

textColor

bars painted with barColor
text painted with textColor

Parameters
cbthe PdfContentByte where the barcode will be placed
barColorthe color of the bars. It can be null
textColorthe color of the text. It can be null
Returns
the dimensions the barcode occupies

Implements iTextSharp.text.pdf.Barcode.

Property Documentation

◆ BarcodeSize

override Rectangle? iTextSharp.text.pdf.BarcodeInter25.BarcodeSize
get

Gets the maximum area that the barcode and the text, if any, will occupy. The lower left corner is always (0, 0).

Returns
the size the barcode occupies.

The documentation for this class was generated from the following file: