| Summary: | XslfoDocumentBuilder should be able to generate a bookmark tree | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Torkild Resheim <torkildr> | ||||||||
| Component: | Mylyn | Assignee: | Torkild Resheim <torkildr> | ||||||||
| Status: | RESOLVED FIXED | QA Contact: | David Green <greensopinion> | ||||||||
| Severity: | enhancement | ||||||||||
| Priority: | P3 | Keywords: | contributed | ||||||||
| Version: | unspecified | ||||||||||
| Target Milestone: | 1.6.0 | ||||||||||
| Hardware: | All | ||||||||||
| OS: | All | ||||||||||
| Whiteboard: | |||||||||||
| Attachments: |
|
||||||||||
|
Description
Torkild Resheim
Have a patch for this. Reassigning to myself. Created attachment 188513 [details]
Patch for XslfoDocumentBuilder to generate XSL:FO bookmarks
If a root outline item is set on the builder prior to document building taking place it will generate XSL:FO bookmarks at the beginning of the resulting document. This will in turn show up as an outline when the document is converted to PDF.
Created attachment 188514 [details]
mylyn/context/zip
I consider this issue fixed. The patch just needs to be applied if there is any interest. Thanks Torkild, your patch looks good. So far WikiText has taken care of this need by emitting generating content as in-document links (ie: hash-tags) before it gets to the document builder. Is this patch for use by WikiText, or are you integrating the XslfoDocumentBuilder directly in your code? Hi David, The patch is for XslfoDocumentBuilder to emit XSL:FO Bookmarks based on the outline generated by WikiText. The end result (after having the FO processed by Apache FOP) is pretty much a table of contents. This is an example where I used WikiText, pages from a MediaWiki instance, Bugzilla queries and JUnit test results to generate release notes in PDF. Depending on your PDF viewer you should be seeing an outline to the left or right of the main content: http://distribute.atmel.no/tools/avr32/beta/as4e-ide-2.7.0.851-readme.pdf (you may have to save the file to disk and open it from there to get the full PDF viewer working). I only did a few adjustments to various parts of WikiText, all filed as patches in the Eclipse Bugzilla. Then used the "wikitext-to-xslfo" Ant task to generate the XSL:FO. Patch applied with modifications. Strengthended the assert in the unit test, also added option to @org.eclipse.mylyn.wikitext.core.util.anttask.MarkupToXslfoTask@ and documentation, so that users of the Ant task can have bookmarks in their PDFs. Created attachment 200322 [details]
mylyn/context/zip
|