📄 barcode.html
字号:
<PRE>
public static final int <B>CODE128_RAW</B></PRE>
<DL>
<DD>A type of barcode
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../../constant-values.html#com.lowagie.text.pdf.Barcode.CODE128_RAW">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="CODABAR"><!-- --></A><H3>
CODABAR</H3>
<PRE>
public static final int <B>CODABAR</B></PRE>
<DL>
<DD>A type of barcode
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../../constant-values.html#com.lowagie.text.pdf.Barcode.CODABAR">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="x"><!-- --></A><H3>
x</H3>
<PRE>
protected float <B>x</B></PRE>
<DL>
<DD>The minimum bar width.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="n"><!-- --></A><H3>
n</H3>
<PRE>
protected float <B>n</B></PRE>
<DL>
<DD>The bar multiplier for wide bars or the distance between bars for Postnet and Planet.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="font"><!-- --></A><H3>
font</H3>
<PRE>
protected <A HREF="../../../../com/lowagie/text/pdf/BaseFont.html">BaseFont</A> <B>font</B></PRE>
<DL>
<DD>The text font. <CODE>null</CODE> if no text.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="size"><!-- --></A><H3>
size</H3>
<PRE>
protected float <B>size</B></PRE>
<DL>
<DD>The size of the text or the height of the shorter bar in Postnet.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="baseline"><!-- --></A><H3>
baseline</H3>
<PRE>
protected float <B>baseline</B></PRE>
<DL>
<DD>If positive, the text distance under the bars. If zero or negative, the text distance above the bars.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="barHeight"><!-- --></A><H3>
barHeight</H3>
<PRE>
protected float <B>barHeight</B></PRE>
<DL>
<DD>The height of the bars.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="textAlignment"><!-- --></A><H3>
textAlignment</H3>
<PRE>
protected int <B>textAlignment</B></PRE>
<DL>
<DD>The text alignment. Can be <CODE>Element.ALIGN_LEFT</CODE>, <CODE>Element.ALIGN_CENTER</CODE> or <CODE>Element.ALIGN_RIGHT</CODE>.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="generateChecksum"><!-- --></A><H3>
generateChecksum</H3>
<PRE>
protected boolean <B>generateChecksum</B></PRE>
<DL>
<DD>The optional checksum generation.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="checksumText"><!-- --></A><H3>
checksumText</H3>
<PRE>
protected boolean <B>checksumText</B></PRE>
<DL>
<DD>Shows the generated checksum in the the text.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="startStopText"><!-- --></A><H3>
startStopText</H3>
<PRE>
protected boolean <B>startStopText</B></PRE>
<DL>
<DD>Show the start and stop character '*' in the text for the barcode 39 or 'ABCD' for codabar.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="extended"><!-- --></A><H3>
extended</H3>
<PRE>
protected boolean <B>extended</B></PRE>
<DL>
<DD>Generates extended barcode 39.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="code"><!-- --></A><H3>
code</H3>
<PRE>
protected <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A> <B>code</B></PRE>
<DL>
<DD>The code to generate.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="guardBars"><!-- --></A><H3>
guardBars</H3>
<PRE>
protected boolean <B>guardBars</B></PRE>
<DL>
<DD>Show the guard bars for barcode EAN.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="codeType"><!-- --></A><H3>
codeType</H3>
<PRE>
protected int <B>codeType</B></PRE>
<DL>
<DD>The code type.
<P>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="Barcode()"><!-- --></A><H3>
Barcode</H3>
<PRE>
public <B>Barcode</B>()</PRE>
<DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="getX()"><!-- --></A><H3>
getX</H3>
<PRE>
public float <B>getX</B>()</PRE>
<DL>
<DD>Gets the minimum bar width.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the minimum bar width</DL>
</DD>
</DL>
<HR>
<A NAME="setX(float)"><!-- --></A><H3>
setX</H3>
<PRE>
public void <B>setX</B>(float x)</PRE>
<DL>
<DD>Sets the minimum bar width.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>x</CODE> - the minimum bar width</DL>
</DD>
</DL>
<HR>
<A NAME="getN()"><!-- --></A><H3>
getN</H3>
<PRE>
public float <B>getN</B>()</PRE>
<DL>
<DD>Gets the bar multiplier for wide bars.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the bar multiplier for wide bars</DL>
</DD>
</DL>
<HR>
<A NAME="setN(float)"><!-- --></A><H3>
setN</H3>
<PRE>
public void <B>setN</B>(float n)</PRE>
<DL>
<DD>Sets the bar multiplier for wide bars.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>n</CODE> - the bar multiplier for wide bars</DL>
</DD>
</DL>
<HR>
<A NAME="getFont()"><!-- --></A><H3>
getFont</H3>
<PRE>
public <A HREF="../../../../com/lowagie/text/pdf/BaseFont.html">BaseFont</A> <B>getFont</B>()</PRE>
<DL>
<DD>Gets the text font. <CODE>null</CODE> if no text.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the text font. <CODE>null</CODE> if no text</DL>
</DD>
</DL>
<HR>
<A NAME="setFont(com.lowagie.text.pdf.BaseFont)"><!-- --></A><H3>
setFont</H3>
<PRE>
public void <B>setFont</B>(<A HREF="../../../../com/lowagie/text/pdf/BaseFont.html">BaseFont</A> font)</PRE>
<DL>
<DD>Sets the text font. <CODE>null</CODE> if no text.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>font</CODE> - the text font. <CODE>null</CODE> if no text</DL>
</DD>
</DL>
<HR>
<A NAME="getSize()"><!-- --></A><H3>
getSize</H3>
<PRE>
public float <B>getSize</B>()</PRE>
<DL>
<DD>Gets the size of the text.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the size of the text</DL>
</DD>
</DL>
<HR>
<A NAME="setSize(float)"><!-- --></A><H3>
setSize</H3>
<PRE>
public void <B>setSize</B>(float size)</PRE>
<DL>
<DD>Sets the size of the text.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>size</CODE> - the size of the text</DL>
</DD>
</DL>
<HR>
<A NAME="getBaseline()"><!-- --></A><H3>
getBaseline</H3>
<PRE>
public float <B>getBaseline</B>()</PRE>
<DL>
<DD>Gets the text baseline. If positive, the text distance under the bars. If zero or negative, the text distance above the bars.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the baseline.</DL>
</DD>
</DL>
<HR>
<A NAME="setBaseline(float)"><!-- --></A><H3>
setBaseline</H3>
<PRE>
public void <B>setBaseline</B>(float baseline)</PRE>
<DL>
<DD>Sets the text baseline. If positive, the text distance under the bars. If zero or negative, the text distance above the bars.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>baseline</CODE> - the baseline.</DL>
</DD>
</DL>
<HR>
<A NAME="getBarHeight()"><!-- --></A><H3>
getBarHeight</H3>
<PRE>
public float <B>getBarHeight</B>()</PRE>
<DL>
<DD>Gets the height of the bars.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the height of the bars</DL>
</DD>
</DL>
<HR>
<A NAME="setBarHeight(float)"><!-- --></A><H3>
setBarHeight</H3>
<PRE>
public void <B>setBarHeight</B>(float barHeight)</PRE>
<DL>
<DD>Sets the height of the bars.
<P>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -