HI Rob, I had forgotten about that feature, but it doesn't seem to control the bookmarks window pane like Richard requested. When the fop1.extensions param is set to 1, the fop1.xsl stylesheet module is used and outputs standard XSL 1.1 bookmark objects. The 'starting-state' attribute is controlled by the DocBook XSL stylesheet param 'bookmarks.collapse', which was added in version 1.75.1:
http://docbook.sourceforge.net/release/xsl/current/doc/fo/bookmarks.collapse.html The param's default value is 1, which sets starting-state="hide" (which actually hides that bookmark's children, not the bookmark itself), so it only shows the top-level bookmarks. The DocBook stylesheet violates the strict hierarchy of the document in one way: it promotes all the children of the root element to top level bookmarks. Otherwise the collapsed state would be a single bookmark for the root element, always requiring a click to expand that to something useful. The promotion therefore displays the top-level list of elements like chapters, etc. If 'bookmarks.collapse' = 0, then all those bookmarks are further expanded into the whole hierarchy in the Bookmarks pane. A little more digging I found this interesting Adobe document entitled Parameters for Opening PDF Files: http://www.adobe.com/content/dam/Adobe/en/devnet/acrobat/pdfs/pdf_open_parameters.pdf I found I could open a PDF file with bookmarks turned off using a command like this: <path-to-acrobat-reader>/acrobat.exe /a pagemode=none filename.pdf That Adobe document also provides URL syntax for setting this feature, so if your PDF is being served by HTTP, you could include the setting in the URL. As far as getting this setting into the PDF document itself, the Antenna House doc says it supports setting pagemode in the axf:document-info extension element. And as Mauritz pointed out earlier, XEP suports a processing instruction <?xep-pdf-view-mode?> that lets you set the initial value. But I don't find any such option for FOP. Bob Stayton Sagehill Enterprises [email protected] From: Cavicchio, Rob Sent: Monday, September 23, 2013 8:43 AM To: Bob Stayton ; Richard Henwood ; Wood Nick ; [email protected] Subject: RE: [docbook-apps] initial pdf view with index side pane It's been a while since I played with it, but I'm pretty sure that if you use XSL 1.1 bookmark objects (rather than the FOP extension for bookmarks), then the value of "starting-state" (show or hide) on the top-level bookmark determines if the bookmark pane is initially displayed. I'm pretty sure this works in FOP 1.0. From: Bob Stayton [mailto:[email protected]] Sent: Thursday, September 19, 2013 10:18 To: Richard Henwood; Wood Nick; [email protected] Subject: Re: [docbook-apps] initial pdf view with index side pane Just for comparison, I checked the Antenna House and XEP documentation regarding PDF options, and neither of them seem to have an option for hiding or displaying the bookmarks pane. I cannot find it in the FOP doc either. I guess the next question is whether the PDF standard even supports control of the bookmarks pane. Bob Stayton Sagehill Enterprises [email protected] From: Richard Henwood Sent: Thursday, September 19, 2013 7:33 AM To: Wood Nick ; [email protected] Subject: Re: [docbook-apps] initial pdf view with index side pane I have set fop1.extensions to 1. I believe this just generates the TOC information and doesn't set the initial view to present the TOC in a left-hand pane... However, I am aware there are a bunch of setting local to my pdf render that may be fiddling with the initial presentation. r, -------------------------------------------------------------------------------- From: Wood Nick <[email protected]> To: "[email protected]" <[email protected]>; Richard Henwood <[email protected]> Sent: Thursday, 19 September 2013, 2:03 Subject: RE: [docbook-apps] initial pdf view with index side pane Richard, Have you set the param fop1.extensions to 1, this works for me. Nick Nick Wood BSc(Hons) MInstLM NATO Communications and Information Agency Chief Document Engineering and Production Section Thier Mathias 1b, B-4690 Bassenge (Glons), Belgium T: +32 42 899215 F: +32 2 707 8770 E: [email protected] W: www.ncia.nato.int From: Bob Stayton [mailto:[email protected]] Sent: Wednesday, September 18, 2013 11:40 PM To: Richard Henwood; [email protected] Subject: Re: [docbook-apps] initial pdf view with index side pane This would be a feature of your XSL-FO processor that generates the PDF. If you are using FOP, you need to look at FOP's PDF output configuration, and see if FOP has such a setting. There is no way to do it in DocBook XSL. Bob Stayton Sagehill Enterprises [email protected] From: Richard Henwood Sent: Wednesday, September 18, 2013 2:02 PM To: Bob Stayton ; [email protected] Subject: Re: [docbook-apps] initial pdf view with index side pane Hi Bob, What I want is when my viewer opens the PDF (I generated from Docbook) for the first time, it presents the user with the table of contents (the 'index' according to evince) in a panel on the left hand side. This gives the user an overview of the document; without this appearing on initial view, a user may not know it exists. Something like this: http://blog.rockymountaintraining.com/?p=383 r, -------------------------------------------------------------------------------- From: Bob Stayton <[email protected]> To: Richard Henwood <[email protected]>; [email protected] Sent: Wednesday, 18 September 2013, 15:00 Subject: Re: [docbook-apps] initial pdf view with index side pane Hi Richard, Do you mean you want to replace the PDF bookmarks with a back-of-the-book index in the left pane? Bob Stayton Sagehill Enterprises [email protected] From: Richard Henwood Sent: Wednesday, September 18, 2013 12:16 PM To: [email protected] Subject: [docbook-apps] initial pdf view with index side pane Hi All, Is there a switch I can throw to force the PDF that is generated to default to displaying the index as a (left-hand) side bar? The best I could find from my searching was: http://wiki.apache.org/xmlgraphics-fop/ExtensionsForPdf but I am unsure how to interpret this page. Any help would be gratefully appreciated! cheers, Richard
