|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Canvas | +--com.idautomation.linear.BarCode
This is the main class that contains all linear barcode functionality.
Field Summary | |
java.awt.Color |
backColor
background color. |
java.awt.Color |
barColor
color of the bars. |
double |
barHeightCM
bar height in CM. |
int |
barType
symbology of barcode. |
boolean |
checkCharacter
if true, the checksum character will be calculated and appended to the code; Default =True. |
boolean |
checkCharacterInText
if true, the checksum character will be appended to the human readable text; Default =True; checksum characters cannot by displayed for Code 128. |
static int |
CODABAR
|
char |
CODABARStartChar
start character for CODABAR. |
char |
CODABARStopChar
stop character for CODABAR. |
java.lang.String |
code
text to be painted as a barcode. |
static int |
CODE11
|
static int |
CODE128
|
char |
Code128Set
set of character to be used in code 128. |
static int |
CODE39
|
static int |
CODE39EXT
|
static int |
CODE93
|
static int |
CODE93EXT
|
java.lang.String |
codeText
text after encoding. |
static int |
EAN13
|
static int |
EAN8
|
java.awt.Color |
fontColor
color of the text. |
boolean |
guardBars
if true (default), guardbars in EAN and UPC codes will be longer than data bars. |
double |
H
height of bars. |
int |
height
initial preferred height property of the bean |
double |
I
|
static int |
IND25
|
static int |
INTERLEAVED25
|
double |
L
Symbol lentgh in CM. |
double |
leftMarginCM
left margin of the barcode (also know as quite zone). |
static int |
MAT25
|
static int |
MSI
|
double |
N
multiplicator value for width bars. |
static int |
PLANET
|
static int |
POSTNET
|
double |
postnetHeightShortBar
height in CM of POSTNET's short bars. |
double |
postnetHeightTallBar
height in CM of POSTNET's tall bars. |
int |
resolution
resolution used to convert from CM to pixels; Default is the screen resolution of pixels per CM. |
int |
rotate
rotation angle. |
double |
supHeight
height of the supplement. |
java.lang.String |
supplement
user defined 2 or 5 digit supplement for EAN or UPC codes. |
double |
supSeparationCM
Separation in CM between the barcode and the supplement |
java.awt.Font |
textFont
font of the text. |
double |
topMarginCM
top margin of the barcode (also know as quite zone). |
static int |
UCC128
|
static int |
UPCA
|
static int |
UPCE
|
boolean |
UPCEANSupplement2
2 digit supplement for EAN or UPC codes. |
boolean |
UPCEANSupplement5
5 digit supplement for EAN or UPC codes. |
char |
UPCESytem
system to be used in UPCE. |
int |
width
initial preferred width property of the bean |
double |
X
size in CM of modules (narrow bars or spaces). |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
BarCode()
|
Method Summary | |
java.awt.Color |
getBackground()
gets the background color. |
double |
getBarHeightCM()
gets bar height in CM. |
boolean |
getCheckCharacter()
if true, the checksum character will be calculated and appended to the code; Default =True. |
boolean |
getCheckCharacterInText()
if true, the checksum character will be appended to the human readable text; Default =True; checksum characters cannot by displayed for Code 128. |
java.lang.String |
getCODABARStartChar()
gets the start character for CODABAR. |
java.lang.String |
getCODABARStopChar()
gets the stop character for CODABAR. |
java.lang.String |
getCode128Set()
gets the character set to be used in code 128. |
java.lang.String |
getDataToEncode()
text that was painted as a barcode. |
java.awt.Font |
getFont()
gets the font of the text. |
java.awt.Color |
getForeground()
gets color of the bars. |
double |
getLeftMarginCM()
returns the left margin of the barcode (also know as quite zone). |
java.awt.Dimension |
getMinimumSize()
|
double |
getNarrowToWideRatio()
gets the multiplicator value for width bars. |
int |
getPixelsPerCM()
gets the resolution used to convert from CM to pixels; Default is the screen resolution of pixels per CM. |
double |
getPostnetHeightShort()
returns the height in CM of POSTNET's short bars. |
double |
getPostnetHeightTall()
returns the height in CM of POSTNET's tall bars. |
java.awt.Dimension |
getPreferredSize()
returns a size appropriate for the barcode generated, the initial size is 170,70. |
int |
getRotationAngle()
gets the rotation angle. |
java.lang.String |
getSupplementToEncode()
gets the user defined 2 or 5 digit supplement for EAN or UPC codes. |
int |
getSymbologyID()
Returns the symbology type; CODE39=0; CODE39EXT=1; INTERLEAVED25=2; CODE11=3; CODABAR=4; MSI=5; UPCA=6; IND25=7; MAT25=8; CODE93=9; EAN13=10; EAN8=11; UPCE=12; CODE128=13; CODE93EXT=14; POSTNET=15; PLANET=16; UCC128=17; the default is CODE128. |
java.awt.Color |
getTextFontColor()
gets color of the text. |
double |
getTopMarginCM()
returns the top margin of the barcode (also know as quite zone). |
boolean |
getUPCEANSupplement2()
gets the 2 digit supplement for EAN or UPC codes. |
boolean |
getUPCEANSupplement5()
gets the 5 digit supplement for EAN or UPC codes. |
java.lang.String |
getUPCESytem()
gets the system to be used in UPCE. |
double |
getXDimensionCM()
gets the size in CM of modules (narrow bars or spaces). |
void |
paint(java.awt.Graphics g2)
paints the barcode and rotates it if necessary |
void |
setBackground(java.awt.Color newColor)
sets the background color. |
void |
setBarHeightCM(double newBarHeight)
sets bar height in CM. |
void |
setCheckCharacter(boolean newChk)
if true, the checksum character will be calculated and appended to the code; Default =True. |
void |
setCheckCharacterInText(boolean newVal)
if true, the checksum character will be appended to the human readable text; Default =True; checksum characters cannot by displayed for Code 128. |
void |
setCODABARStartChar(java.lang.String newSet)
sets the start character for CODABAR. |
void |
setCODABARStopChar(java.lang.String newSet)
sets the stop character for CODABAR. |
void |
setCode128Set(java.lang.String newSet)
sets the character set to be used in code 128. |
void |
setDataToEncode(java.lang.String newCode)
text to be painted as a barcode. |
void |
setFont(java.awt.Font newFont)
sets the font of the text. |
void |
setForeground(java.awt.Color newColor)
sets color of the bars. |
void |
setLeftMarginCM(double newMargin)
left margin of the barcode (also know as quite zone). |
void |
setNarrowToWideRatio(double newN)
sets the multiplicator value for width bars. |
void |
setPixelsPerCM(int newRes)
sets the resolution used to convert from CM to pixels; Default is the screen resolution of pixels per CM. |
void |
setPostnetHeightShort(double newHeight)
height in CM of POSTNET's short bars. |
void |
setPostnetHeightTall(double newHeight)
height in CM of POSTNET's tall bars. |
void |
setRotationAngle(int newRotate)
sets the rotation angle. |
void |
setSupplementToEncode(java.lang.String newCode)
sets the user defined 2 or 5 digit supplement for EAN or UPC codes. |
void |
setSymbologyID(int newSym)
To change the symbology type, set the appropriate number for the SymbologyID property: CODE39=0; CODE39EXT=1; INTERLEAVED25=2; CODE11=3; CODABAR=4; MSI=5; UPCA=6; IND25=7; MAT25=8; CODE93=9; EAN13=10; EAN8=11; UPCE=12; CODE128=13; CODE93EXT=14; POSTNET=15; PLANET=16; UCC128=17; the default is CODE128. |
void |
setTextFontColor(java.awt.Color newColor)
sets color of the text. |
void |
setTopMarginCM(double newMargin)
top margin of the barcode (also know as quite zone). |
void |
setUPCEANSupplement2(boolean newval)
sets the 2 digit supplement for EAN or UPC codes. |
void |
setUPCEANSupplement5(boolean newval)
sets the 5 digit supplement for EAN or UPC codes. |
void |
setUPCESytem(java.lang.String newSet)
sets the system to be used in UPCE. |
void |
setXDimensionCM(double newX)
sets the size in CM of modules (narrow bars or spaces). |
Methods inherited from class java.awt.Canvas |
addNotify, getAccessibleContext |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, contains, contains, createImage, createImage, deliverEvent, disable, dispatchEvent, doLayout, enable, enable, enableInputMethods, getAlignmentX, getAlignmentY, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getCursor, getDropTarget, getFontMetrics, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getName, getParent, getPeer, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, update, validate |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int CODE39
public static final int CODE39EXT
public static final int INTERLEAVED25
public static final int CODE11
public static final int CODABAR
public static final int MSI
public static final int UPCA
public static final int IND25
public static final int MAT25
public static final int CODE93
public static final int EAN13
public static final int EAN8
public static final int UPCE
public static final int CODE128
public static final int CODE93EXT
public static final int POSTNET
public static final int PLANET
public static final int UCC128
public int barType
public java.lang.String code
public boolean checkCharacter
public boolean checkCharacterInText
public double postnetHeightTallBar
public double postnetHeightShortBar
public double leftMarginCM
public double topMarginCM
public java.lang.String supplement
public boolean guardBars
public java.awt.Color backColor
public java.lang.String codeText
public int resolution
public double barHeightCM
public int width
public int height
public java.awt.Font textFont
public java.awt.Color fontColor
public java.awt.Color barColor
public char UPCESytem
public char CODABARStartChar
public char CODABARStopChar
public boolean UPCEANSupplement2
public boolean UPCEANSupplement5
public char Code128Set
public double X
public double N
public double I
public double H
public double L
public int rotate
public double supSeparationCM
public double supHeight
Constructor Detail |
public BarCode()
Method Detail |
public void setSymbologyID(int newSym)
public int getSymbologyID()
public void setDataToEncode(java.lang.String newCode)
public java.lang.String getDataToEncode()
public void setCheckCharacter(boolean newChk)
public boolean getCheckCharacter()
public void setCheckCharacterInText(boolean newVal)
public boolean getCheckCharacterInText()
public void setPostnetHeightTall(double newHeight)
public double getPostnetHeightTall()
public void setPostnetHeightShort(double newHeight)
public double getPostnetHeightShort()
public void setLeftMarginCM(double newMargin)
public double getLeftMarginCM()
public void setTopMarginCM(double newMargin)
public double getTopMarginCM()
public void setSupplementToEncode(java.lang.String newCode)
public java.lang.String getSupplementToEncode()
public void setBackground(java.awt.Color newColor)
setBackground
in class java.awt.Component
public java.awt.Color getBackground()
getBackground
in class java.awt.Component
public void setPixelsPerCM(int newRes)
public int getPixelsPerCM()
public void setBarHeightCM(double newBarHeight)
public double getBarHeightCM()
public java.awt.Dimension getPreferredSize()
getPreferredSize
in class java.awt.Component
public java.awt.Dimension getMinimumSize()
getMinimumSize
in class java.awt.Component
public void setFont(java.awt.Font newFont)
setFont
in class java.awt.Component
public java.awt.Font getFont()
getFont
in class java.awt.Component
public void setTextFontColor(java.awt.Color newColor)
public java.awt.Color getTextFontColor()
public void setForeground(java.awt.Color newColor)
setForeground
in class java.awt.Component
public java.awt.Color getForeground()
getForeground
in class java.awt.Component
public void setUPCESytem(java.lang.String newSet)
public java.lang.String getUPCESytem()
public void setCODABARStartChar(java.lang.String newSet)
public java.lang.String getCODABARStartChar()
public void setCODABARStopChar(java.lang.String newSet)
public java.lang.String getCODABARStopChar()
public void setUPCEANSupplement2(boolean newval)
public boolean getUPCEANSupplement2()
public void setUPCEANSupplement5(boolean newval)
public boolean getUPCEANSupplement5()
public void setCode128Set(java.lang.String newSet)
public java.lang.String getCode128Set()
public void setXDimensionCM(double newX)
public double getXDimensionCM()
public void setNarrowToWideRatio(double newN)
public double getNarrowToWideRatio()
public void setRotationAngle(int newRotate)
public int getRotationAngle()
public void paint(java.awt.Graphics g2)
paint
in class java.awt.Canvas
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |