org.apache.fop.pdf
Class PDFRoot
- PDFWritable
Class representing a Root (/Catalog) object.
encode , encodeBinaryToHexString , encodeString , encodeText , formatDateTime , formatDateTime , formatObject , getDocument , getDocumentSafely , getGeneration , getObjectID , getObjectNumber , getParent , hasObjectNumber , makeReference , output , outputInline , referencePDF , setDocument , setObjectNumber , setParent , toPDF , toPDFString |
PAGEMODE_FULLSCREEN
public static final int PAGEMODE_FULLSCREEN
Full screen page mode
PAGEMODE_USENONE
public static final int PAGEMODE_USENONE
Use no page mode setting, default
PAGEMODE_USEOUTLINES
public static final int PAGEMODE_USEOUTLINES
Use outlines page mode to show bookmarks
PAGEMODE_USETHUMBS
public static final int PAGEMODE_USETHUMBS
Use thumbs page mode to show thumbnail images
PDFRoot
public PDFRoot(int objnum,
PDFPages pages)
create a Root (/Catalog) object. NOTE: The PDFRoot
object must be created before the PDF document is
generated, but it is not assigned an object ID until
it is about to be written (immediately before the xref
table as part of the trsailer). (mark-fop@inomial.com)
objnum
- the object's numberpages
- the PDFPages object
addOutputIntent
public void addOutputIntent(PDFOutputIntent outputIntent)
Adds an OutputIntent to the PDF
outputIntent
- the OutputIntent dictionary
addPage
public void addPage(PDFPage page)
add a /Page object to the root /Pages object
page
- the /Page object to add
getLanguage
public String getLanguage()
Returns the language identifier of the document.
- the language identifier of the document (or null if not set or undefined)
getMetadata
public PDFMetadata getMetadata()
Returns the /Metadata object
- the /Metadata object if set, null otherwise.
getNames
public PDFNames getNames()
Returns the /Names object.
- the Names object if set, null otherwise.
getOutputIntents
public PDFArray getOutputIntents()
Returns the /OutputIntents array.
- the /OutputIntents array or null if it doesn't exist
getPageLabels
public PDFPageLabels getPageLabels()
Returns the /PageLabels object.
- the /PageLabels object if set, null otherwise.
getPageMode
public int getPageMode()
Returns the currently active /PageMode.
- the /PageMode (one of PAGEMODE_*)
getRootOutline
public PDFOutline getRootOutline()
Get the root PDF outline for the document.
getRootPages
public PDFPages getRootPages()
Returns the /PageLabels object.
- the /PageLabels object if set, null otherwise.
setLanguage
public void setLanguage(String lang)
Sets the language identifier of the document.
lang
- the language identifier of the document.
setMetadata
public void setMetadata(PDFMetadata meta)
Set the optional Metadata object.
meta
- the Metadata object
setNames
public void setNames(PDFNames names)
Set the /Names object.
setPageLabels
public void setPageLabels(PDFPageLabels pageLabels)
Sets the /PageLabels object.
pageLabels
- the /PageLabels object
setPageMode
public void setPageMode(int mode)
Set the page mode for the PDF document.
mode
- the page mode (one of PAGEMODE_*)
setRootOutline
public void setRootOutline(PDFOutline out)
Set the root outline for the PDF document.
out
- the root PDF Outline
setRootPages
public void setRootPages(PDFPages pages)
set the root /Pages object
pages
- the /Pages object to set as root
Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.