import org.apache.fop.pdf.PDFAnnotList;
import org.apache.fop.pdf.PDFColor;
import org.apache.fop.pdf.PDFConformanceException;
+import org.apache.fop.pdf.PDFDestination;
import org.apache.fop.pdf.PDFDocument;
import org.apache.fop.pdf.PDFEncryptionManager;
import org.apache.fop.pdf.PDFEncryptionParams;
import org.apache.xmlgraphics.xmp.schemas.XMPBasicAdapter;
import org.apache.xmlgraphics.xmp.schemas.XMPBasicSchema;
+import org.apache.fop.area.DestinationData;
+
/**
* Renderer that renders areas to PDF.
*/
* @see org.apache.fop.render.Renderer#processOffDocumentItem(OffDocumentItem)
*/
public void processOffDocumentItem(OffDocumentItem odi) {
+ // render Destinations
+ if (odi instanceof DestinationData) {
+ PDFDestination destination = pdfDoc.getFactory().makeDestination((DestinationData) odi);
+ PageViewport pv = destination.getPageViewport();
+ String dest = (String)pageReferences.get(pv.getKey());
+ destination.setGoToReference(dest);
+ }
// render Bookmark-Tree
- if (odi instanceof BookmarkData) {
+ else if (odi instanceof BookmarkData) {
renderBookmarkTree((BookmarkData) odi);
} else if (odi instanceof OffDocumentExtensionAttachment) {
ExtensionAttachment attachment = ((OffDocumentExtensionAttachment)odi).getAttachment();