Installation and Use of iReport4.5.1 fonts and handling of pdf Fonts

Source: Internet
Author: User

Installation and Use of iReport4.5.1 fonts and handling of pdf Fonts
 

 

To use additional fonts, you must add a font file. This article applies:

1.pdf Chinese Garbled text, pdf Chinese not displayed

2. Use the new font file and install it in jasper

3. Solve exceptions caused by the latest jar files and the jar packages of iText of different versions

For pdf Processing, we use open-source iText.

The procedure is as follows:

① Select Tools --> and open the following panel.

Then select Install Font

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J322P-0.png "/>

② Select the font file location. Select the font file under your operating system.

C: \ windows \ fonts \ simfang. ttf font.

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J33516-1.png "/>

SelectPDF Encoding -- "Identity-H

Check Embed this font in the pdf document

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J34I6-2.png "/>

④. The next few steps are all the way to next.

⑤ Export the font to a jar file, and then put the font file into our project,

SelectExport as extension

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J363X-3.png "/>

 

⑥ Select the storage location. This jar file needs to be introduced in the classpath of iReport.

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J35358-4.png "/>

Finish

 

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J36008-5.png "/>

In addition: for pdf Processing, the previous article has mentioned several jar files. Here, the next statement is as follows:

Latest Version of iText: itext-5.3.2

Another jar file is required for processing Chinese characters.

Extrajars-2.2 located under itext-asian.jar

The http://sourceforge.net/projects/itext/files/ of the two files

One in iText and one in extrajars

 

650) this. width = 650; "border =" 0 "alt =" "src =" http://www.bkjia.com/uploads/allimg/131228/121J3L62-6.png "/>

Note: Some of the old articles may have been written by some authors in the past, for the iReport-4.5.4, some of the jar files used to deal with pdf Chinese has been changed, modified, therefore, use the latest jar file to ensure that the project runs properly!

Now, you should have learned how to process Chinese characters using jasper.

This article from the ghost Conan technology blog, please be sure to keep this source http://enetq.blog.51cto.com/479739/975303

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.