Chapter 12. Drawing to Java Graphics2D
This chapter covers
iText and Java’s
Graphics2Djava.awt.fontvs.com.lowagie.text.FontSwing components and PDF
PDF and Optional Content
In the two previous chapters, we’ve been discussing methods to draw graphics and text using iText’s direct content object PdfContentByte. You may have recognized some of the examples from other books on SVG, PostScript, or Java graphics. For instance, all the graphical shapes you drew in chapter 10 also exist in the standard Java Developer Kit (JDK): The package java.awt.geom has objects such as Rectangle2D, Ellipse2D, CubicCurve2D, and so on.
Maybe you’re already familiar with these objects. If that is the case, you can use iText as a PDF engine for all your Graphics2D requirements. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access