百科.dev
全部条目AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
I

itext-java

> 数据库
开源

iText for Java 是面向希望利用 PDF 带来的优势的开发人员的下一代 SDK。它配备了更先进的文档引擎,

2.3K stars0 点赞0 次浏览
访问官网GitHub

工具介绍

iText for Java 是面向希望利用 PDF 带来的优势的开发人员的下一代 SDK。它配备了更先进的文档引擎,

iText Core/Community is a high-performance, battle-tested library that allows you to create, adapt, inspect and maintain PDF documents, allowing you to add PDF functionality to your software projects with ease. It is also available for .[NET][itextdotnet] (C#). ### The key features of iText Core/Community are: * Core library: * PDF creation with the use of our layout engine * PDF manipulation, e.g. merging multiple PDFs into one, adding new content, ... * PDF digital signing * PDF form creation and manipulation * Working with PDF/A documents * Working with PDF/UA documents * FIPS-compliant cryptography * Barcode generation * SVG support * [Addons:][all products] * Converting XML/HTML & CSS to PDF [repo][pdfhtml], [info][pdfhtmlproduct] * Perform OCR on images and PDF documents [repo][pdfocr], [info][pdfocrproduct] * Redacting sensitive information in PDF documents [repo][pdfsweep], [info][pdfsweepproduct] * Support for international character sets (e.g. Arabic, Chinese, Hebrew, Thai, ...) [info][calligraph] * Optimize PDF documents for reduced file size, and increased performance [info][optimizer] * Flattening XFA documents [info][xfa] * PDF debugging [repo][rups], [info][rupsproduct] Want to discover what's possible? Head over to our [Demo Lab](https://itextpdf.com/demos)! It contains a collection of demo applications ready to use online! ### Getting started The easiest way to get started is to use Maven, just add the following entries to your pom.xml file: ```html REPLACE_WITH_DESIRED_ITEXT_VERSION com.itextpdf itext-core ${itext.version} pom com.itextpdf bouncy-castle-adapter ${itext.version} ``` For more advanced use cases, please refer to the [Installation guidelines](https://kb.itextpdf.com/home/it7kb/installation-guidelines). You can also [build iText Community from source][building]. ### Hello PDF! The following example shows how easy it is to create a simple PDF document: ```java package com.itextpdf.hellopdf; import com.itextpdf.kernel.pdf.PdfDocument; import com.itextpdf.kernel.pdf.PdfWriter; import com.itextpdf.layout.Document; import com.itextpdf.layout.element.Paragraph; import java.io.FileNotFoundException; public class HelloPdfApp { public static void main(String[] args) throws FileNotFoundException { try (Document document = new Document(new PdfDocument(new PdfWriter("./hello-pdf.pdf")))) { document.add(new Paragraph("Hello PDF!")); } } } ``` ### GraalVM compatibility Starting from version 8.0.3 iText Core supports native image compilation using GraalVM. See [building] for details. ### Examples This is a small subset of examples to get you started. For more advanced examples, refer to our [Knowledge Base](https://kb.itextpdf.com/home/it7kb/examples) or the following links: [Examples repo](https://github.com/itext/itext-publications-examples-java), [Signing examples](https://github.com/itext/itext-publications-signing-examples-java). Some of the output PDF files will be incorrectly displayed by the GitHub previewer, so be sure to download them to see the correct results. | Description | Link | |---------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | **Basic layout** | | | Change text properties | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/layout/ParagraphTextWithStyle.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/layout/cmp_paragraphTextWithStyle.pdf) | | Creating a simple table | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/tables/SimpleTable9.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/tables/cmp_simple_table9.pdf) | | Add an image to a PDF document | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/images/MultipleImages.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/images/cmp_multiple_images.pdf) | | Create a list | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/objects/NestedLists.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/objects/cmp_nested_list.pdf) | | Add a watermark | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/events/Watermarking.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/events/cmp_watermarkings.pdf) | | Add links to navigate within a document | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/annotations/AddLinkAnnotation5.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/annotations/cmp_add_link_annotation5.pdf) | | Create a popup annotation | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/annotations/MovePopup.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/annotations/cmp_move_popup.pdf) | | Change font | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/layout/ParagraphTextWithStyle.java) | | Add form fields | [Java](https://kb.itextpdf.com/home/it7kb/examples/forms-in-itext-core-8-0-0) | |
| | | **General document settings** | | | Change page size and margin | [Java](https://github.com/itext/itext-publications-examples-java/blob/master/src/main/java/com/itextpdf/samples/sandbox/layout/PageSizeAndMargins.java), [PDF](https://github.com/itext/itext-publications-examples-java/blob/master/cmpfiles/sandbox/layout/cmp_pageSizeAndMargins.pdf)

GitHub Issues· 0 开放

在 GitHub 查看全部

暂无开放 Issues,或尚未同步最近议题。

> 标签

Javaaccessibilityacroformarchivingccpa

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类数据库
定价开源

> 相关工具

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库