Package org.apache.pdfbox.examples.pdmodel
These examples show how to use the classes in the PDModel package.
-
Class Summary Class Description AddAnnotations Add annotations to pages of a PDF document.AddImageToPDF This is an example that creates a reads a document and adds an image to it..AddJavascript This is an example of how to set some javascript in the document.AddMessageToEachPage This is an example of how to add a message to every page in a pdf document.AddMetadataFromDocInfo This is an example on how to add metadata to a document.BengaliPdfGenerationHelloWorld Inspired from PdfBox Example.CreateBlankPDF Create a blank PDF and write the contents to a file.CreateBookmarks This is an example on how to add bookmarks to a PDF document.CreateGradientShadingPDF This example creates a PDF with type 2 (axial) and type 3 (radial) shadings with a type 2 (exponential) function, and a type 4 (gouraud triangle shading) without function.CreateLandscapePDF This is an example of how to create a page with a landscape orientation.CreatePageLabels Create a 3-page PDF with the page labels "RO III", "RO IV", "1".CreatePatternsPDF This is an example of how to create a page that uses patterns to paint areas.CreatePDFA Creates a simple PDF/A document.CreatePortableCollection This is an example on how to create a portable collection PDF, as described in the PDF 1.7 specification in chapter 12.3.5.CreateSeparationColorBox This example shows how to use a separation color / spot color.EmbeddedFiles This is an example that creates a simple document and embeds a file into it..EmbeddedFonts An example of using an embedded TrueType font with Unicode text.EmbeddedMultipleFonts Output a text without knowing which font is the right one.EmbeddedVerticalFonts ExtractEmbeddedFiles This is an example on how to extract all embedded files from a PDF document.ExtractMetadata This is an example on how to extract metadata from a PDF document.ExtractTTFFonts This will extract all true type-fonts of a pdf.GoToSecondBookmarkOnOpen This is an example on how to an action to go to the second page when the PDF is opened.HelloWorld Creates a "Hello World" PDF using the built-in Helvetica font.HelloWorldTTF Creates a simple document with a TrueType font.HelloWorldType1 Creates a simple document with a Type 1 font (.pfb).ImageToPDF Creates a PDF document from an image.PrintBookmarks This is an example on how to access the bookmarks that are part of a pdf document.PrintDocumentMetaData This is an example on how to get a documents metadata information.PrintURLs This is an example of how to access a URL in a PDF document.RemoveFirstPage This is an example on how to remove pages from a PDF document.ReplaceURLs This is an example of how to replace a URL in a PDF document.RubberStamp This is an example on how to add annotations to pages of a PDF document.RubberStampWithImage This is an example on how to add a rubber stamp annotation with an image to pages of a PDF document.ShowColorBoxes Creates a simple document.ShowTextWithPositioning This example shows how to justify a string using the showTextWithPositioning method.SuperimposePage Example to show superimposing a PDF page onto another PDF.UsingTextMatrix This is an example of how to use a text matrix.