jasperreport生成pdf_jasperreport 导出excel_jasperreport json(43)

电脑杂谈  发布时间:2017-02-04 10:28:36  来源:网络整理

Helvetica

Helvetica-Bold

Helvetica-BoldOblique

Helvetica-Oblique

Symbol

Times-Roman

Times-Bold

Times-BoldItalic

Times-Italic

ZapfDingbats

The iText library requires us to specify either a built-in font name from the above list, either the name

of a TTF file that it can locate on disk, every time we work with fonts. The font name introduced by the

fontName attribute previously explained is of no use when exporting to PDF. This is why we have

special font attributes, so that we are able to specify the font settings that the iText library expects from

us.

The pdfFontName attribute can contain the name of a PDF built-in font from the above list or the

name of a TTF file that can be located on disk at runtime, when exporting to PDF.

It is for the report design creator to choose the right value for the pdfFontName attribute

that would perfectly corresponds to the Java physical or logical font specified using the

fontName attribute. If those two fonts, one used by the Java viewers and printers and the

other used in the PDF format, do not represent in fact the same font, or do not at least look

alike, you might get unexpected results when exporting to PDF format.

Additional PDF fonts can be installed on your system if you choose one of the Acrobat Reader's font

packs. For example, by installing the Asian font pack from Adobe on your system, you would be able

to use for the pdfFontName attribute font names like:

Language PDF Font Name

Simplified Chinese STSong-Light

Traditional Chinese MHei-Medium


本文来自电脑杂谈,转载请注明本文网址:
https://www.pc-fly.com/a/ruanjian/article-30468-43.html

相关阅读
    发表评论  请自觉遵守互联网相关的政策法规,严禁发布、暴力、反动的言论

    热点图片
    拼命载入中...