public class HeaderFooterBookmarksExportMode
Example:
Document doc = new Document(getMyDir() + "Bookmarks in headers and footers.docx");
// You can specify how bookmarks in headers/footers are exported
// There is a several options for this:
// "None" - Bookmarks in headers/footers are not exported
// "First" - Only bookmark in first header/footer of the section is exported
// "All" - Bookmarks in all headers/footers are exported
PdfSaveOptions saveOptions = new PdfSaveOptions();
saveOptions.setHeaderFooterBookmarksExportMode(headerFooterBookmarksExportMode);
saveOptions.getOutlineOptions().setDefaultBookmarksOutlineLevel(1);
saveOptions.setPageMode(PdfPageMode.USE_OUTLINES);
doc.save(getArtifactsDir() + "PdfSaveOptions.HeaderFooterBookmarksExportMode.pdf", saveOptions);
Field Summary | ||
---|---|---|
static final int | NONE | |
Bookmarks in headers/footers are not exported.
|
||
static final int | FIRST | |
Only bookmark in first header/footer of the section is exported.
|
||
static final int | ALL | |
Bookmarks in all headers/footers are exported.
|