⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 barcode.html

📁 IText PDF开发工具说明文档,使用很方便。
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<A NAME="isExtended()"><!-- --></A><H3>isExtended</H3><PRE>public boolean <B>isExtended</B>()</PRE><DL><DD>Gets the property to generate extended barcode 39.<P><DD><DL><DT><B>Returns:</B><DD>value of property extended.</DL></DD></DL><HR><A NAME="setExtended(boolean)"><!-- --></A><H3>setExtended</H3><PRE>public void <B>setExtended</B>(boolean&nbsp;extended)</PRE><DL><DD>Sets the property to generate extended barcode 39.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>extended</CODE> - new value of property extended</DL></DD></DL><HR><A NAME="getCode()"><!-- --></A><H3>getCode</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getCode</B>()</PRE><DL><DD>Gets the code to generate.<P><DD><DL><DT><B>Returns:</B><DD>the code to generate</DL></DD></DL><HR><A NAME="setCode(java.lang.String)"><!-- --></A><H3>setCode</H3><PRE>public void <B>setCode</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;code)</PRE><DL><DD>Sets the code to generate.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>code</CODE> - the code to generate</DL></DD></DL><HR><A NAME="isGuardBars()"><!-- --></A><H3>isGuardBars</H3><PRE>public boolean <B>isGuardBars</B>()</PRE><DL><DD>Gets the property to show the guard bars for barcode EAN.<P><DD><DL><DT><B>Returns:</B><DD>value of property guardBars</DL></DD></DL><HR><A NAME="setGuardBars(boolean)"><!-- --></A><H3>setGuardBars</H3><PRE>public void <B>setGuardBars</B>(boolean&nbsp;guardBars)</PRE><DL><DD>Sets the property to show the guard bars for barcode EAN.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>guardBars</CODE> - new value of property guardBars</DL></DD></DL><HR><A NAME="getCodeType()"><!-- --></A><H3>getCodeType</H3><PRE>public int <B>getCodeType</B>()</PRE><DL><DD>Gets the code type.<P><DD><DL><DT><B>Returns:</B><DD>the code type</DL></DD></DL><HR><A NAME="setCodeType(int)"><!-- --></A><H3>setCodeType</H3><PRE>public void <B>setCodeType</B>(int&nbsp;codeType)</PRE><DL><DD>Sets the code type.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>codeType</CODE> - the code type</DL></DD></DL><HR><A NAME="getBarcodeSize()"><!-- --></A><H3>getBarcodeSize</H3><PRE>public abstract <A HREF="../../../../com/lowagie/text/Rectangle.html" title="class in com.lowagie.text">Rectangle</A> <B>getBarcodeSize</B>()</PRE><DL><DD>Gets the maximum area that the barcode and the text, if any, will occupy. The lower left corner is always (0, 0).<P><DD><DL><DT><B>Returns:</B><DD>the size the barcode occupies.</DL></DD></DL><HR><A NAME="placeBarcode(com.lowagie.text.pdf.PdfContentByte, java.awt.Color, java.awt.Color)"><!-- --></A><H3>placeBarcode</H3><PRE>public abstract <A HREF="../../../../com/lowagie/text/Rectangle.html" title="class in com.lowagie.text">Rectangle</A> <B>placeBarcode</B>(<A HREF="../../../../com/lowagie/text/pdf/PdfContentByte.html" title="class in com.lowagie.text.pdf">PdfContentByte</A>&nbsp;cb,                                       <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;barColor,                                       <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;textColor)</PRE><DL><DD>Places the barcode in a <CODE>PdfContentByte</CODE>. The barcode is always placed at coordinates (0, 0). Use the translation matrix to move it elsewhere.<p> The bars and text are written in the following colors:<p> <P><TABLE BORDER=1> <TR>    <TH><P><CODE>barColor</CODE></TH>    <TH><P><CODE>textColor</CODE></TH>    <TH><P>Result</TH>    </TR> <TR>    <TD><P><CODE>null</CODE></TD>    <TD><P><CODE>null</CODE></TD>    <TD><P>bars and text painted with current fill color</TD>    </TR> <TR>    <TD><P><CODE>barColor</CODE></TD>    <TD><P><CODE>null</CODE></TD>    <TD><P>bars and text painted with <CODE>barColor</CODE></TD>    </TR> <TR>    <TD><P><CODE>null</CODE></TD>    <TD><P><CODE>textColor</CODE></TD>    <TD><P>bars painted with current color<br>text painted with <CODE>textColor</CODE></TD>    </TR> <TR>    <TD><P><CODE>barColor</CODE></TD>    <TD><P><CODE>textColor</CODE></TD>    <TD><P>bars painted with <CODE>barColor</CODE><br>text painted with <CODE>textColor</CODE></TD>    </TR> </TABLE><P><DD><DL><DT><B>Parameters:</B><DD><CODE>cb</CODE> - the <CODE>PdfContentByte</CODE> where the barcode will be placed<DD><CODE>barColor</CODE> - the color of the bars. It can be <CODE>null</CODE><DD><CODE>textColor</CODE> - the color of the text. It can be <CODE>null</CODE><DT><B>Returns:</B><DD>the dimensions the barcode occupies</DL></DD></DL><HR><A NAME="createTemplateWithBarcode(com.lowagie.text.pdf.PdfContentByte, java.awt.Color, java.awt.Color)"><!-- --></A><H3>createTemplateWithBarcode</H3><PRE>public <A HREF="../../../../com/lowagie/text/pdf/PdfTemplate.html" title="class in com.lowagie.text.pdf">PdfTemplate</A> <B>createTemplateWithBarcode</B>(<A HREF="../../../../com/lowagie/text/pdf/PdfContentByte.html" title="class in com.lowagie.text.pdf">PdfContentByte</A>&nbsp;cb,                                             <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;barColor,                                             <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;textColor)</PRE><DL><DD>Creates a template with the barcode.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>cb</CODE> - the <CODE>PdfContentByte</CODE> to create the template. It serves no other use<DD><CODE>barColor</CODE> - the color of the bars. It can be <CODE>null</CODE><DD><CODE>textColor</CODE> - the color of the text. It can be <CODE>null</CODE><DT><B>Returns:</B><DD>the template<DT><B>See Also:</B><DD><A HREF="../../../../com/lowagie/text/pdf/Barcode.html#placeBarcode(com.lowagie.text.pdf.PdfContentByte, java.awt.Color, java.awt.Color)"><CODE>placeBarcode(PdfContentByte cb, Color barColor, Color textColor)</CODE></A></DL></DD></DL><HR><A NAME="createImageWithBarcode(com.lowagie.text.pdf.PdfContentByte, java.awt.Color, java.awt.Color)"><!-- --></A><H3>createImageWithBarcode</H3><PRE>public <A HREF="../../../../com/lowagie/text/Image.html" title="class in com.lowagie.text">Image</A> <B>createImageWithBarcode</B>(<A HREF="../../../../com/lowagie/text/pdf/PdfContentByte.html" title="class in com.lowagie.text.pdf">PdfContentByte</A>&nbsp;cb,                                    <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;barColor,                                    <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;textColor)</PRE><DL><DD>Creates an <CODE>Image</CODE> with the barcode.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>cb</CODE> - the <CODE>PdfContentByte</CODE> to create the <CODE>Image</CODE>. It serves no other use<DD><CODE>barColor</CODE> - the color of the bars. It can be <CODE>null</CODE><DD><CODE>textColor</CODE> - the color of the text. It can be <CODE>null</CODE><DT><B>Returns:</B><DD>the <CODE>Image</CODE><DT><B>See Also:</B><DD><A HREF="../../../../com/lowagie/text/pdf/Barcode.html#placeBarcode(com.lowagie.text.pdf.PdfContentByte, java.awt.Color, java.awt.Color)"><CODE>placeBarcode(PdfContentByte cb, Color barColor, Color textColor)</CODE></A></DL></DD></DL><HR><A NAME="createAwtImage(java.awt.Color, java.awt.Color)"><!-- --></A><H3>createAwtImage</H3><PRE>public abstract <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Image.html?is-external=true" title="class or interface in java.awt">Image</A> <B>createAwtImage</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;foreground,                                     <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/Color.html?is-external=true" title="class or interface in java.awt">Color</A>&nbsp;background)</PRE><DL><DD>Creates a <CODE>java.awt.Image</CODE>. This image only contains the bars without any text.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>foreground</CODE> - the color of the bars<DD><CODE>background</CODE> - the color of the background<DT><B>Returns:</B><DD>the image</DL></DD></DL><HR><A NAME="getInkSpreading()"><!-- --></A><H3>getInkSpreading</H3><PRE>public float <B>getInkSpreading</B>()</PRE><DL><DD>Gets the amount of ink spreading.<P><DD><DL><DT><B>Returns:</B><DD>the ink spreading</DL></DD></DL><HR><A NAME="setInkSpreading(float)"><!-- --></A><H3>setInkSpreading</H3><PRE>public void <B>setInkSpreading</B>(float&nbsp;inkSpreading)</PRE><DL><DD>Sets the amount of ink spreading. This value will be subtracted to the width of each bar. The actual value will depend on the ink and the printing medium.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>inkSpreading</CODE> - the ink spreading</DL></DD></DL><HR><A NAME="getAltText()"><!-- --></A><H3>getAltText</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getAltText</B>()</PRE><DL><DD>Gets the alternate text.<P><DD><DL><DT><B>Returns:</B><DD>the alternate text</DL></DD></DL><HR><A NAME="setAltText(java.lang.String)"><!-- --></A><H3>setAltText</H3><PRE>public void <B>setAltText</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;altText)</PRE><DL><DD>Sets the alternate text. If present, this text will be used instead of the text derived from the supplied code.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>altText</CODE> - the alternate text</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>Hosted by <a href="http://www.hostbasket.com/">Hostbasket</a></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../../com/lowagie/text/pdf/BadPdfFormatException.html" title="class in com.lowagie.text.pdf"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../../../com/lowagie/text/pdf/Barcode128.html" title="class in com.lowagie.text.pdf"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../../index.html?com/lowagie/text/pdf/Barcode.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="Barcode.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -