Can you make the HTML5 ToC look like PDF Bookmarks listing?

This forum is for Single-Sourcing your Flare content to multiple outputs.
Post Reply
mlaird
Propeller Head
Posts: 49
Joined: Wed Feb 06, 2013 3:18 pm

Can you make the HTML5 ToC look like PDF Bookmarks listing?

Post by mlaird »

Hello!

I'm trying to wrap my head around the way that certain differences in output types work in Flare, and to see if there are any ways to work around these differences that I don't know about. I'm going to try to be clear about my questions, but they all revolve around ToCs, which are a fairly loaded term in the world of Flare, so I apologize in advance if I don't do a good enough job of keeping things straight!

We have been creating PDF documentation for a while now, and we're now working to start creating HTML versions of the documents we already have in PDF (we will also be making new documents with the same / similar content and a different structure, but that's not what I'm asking about here). What I'm trying to figure out how to do is use the same ToC (the *.fltoc file) to generate both the PDF and HTML outputs. I've created different targets, I have certain types of content (such as title page) marked as either print or screen-only using conditions, and all of that works fine.

The thing that I'm stuck on right now is the difference in the way that the 'Contents' menu is generated for HTML5 output, compared with the way that either the ToC Proxy or PDF Bookmarks pane are generated for PDF output. I believe I understand the differences, but I want to see if there's a way to get the HTML5 Contents more in-line with the ToC that gets generated for PDF Bookmarks, or if I'm going to need to do some serious reorganizing of my project structure.

Right now, the *.fltocs that I use are fairly simple. I have a topic for each section, and the topic itself is filled with various levels of headings and mostly snippets. The PDF Bookmarks are generated from those headings, so I get something like this:

Heading level 1
- Heading level 2
- Heading level 2
- - Heading level 3
- Heading level 2
Heading level 1

(sorry for the rough representation)

On the other hand, the Contents that appear for HTML5 help are based precisely on the actual *.fltoc file, and since that only has a topic link for each section, when I generate HTML5 help, I get this:

Heading level 1
Heading level 1
Heading level 1

What is the best way to fix this? I imagine I could create a second ToC for the online help and manually create items that point to each heading in all of the topics, but that seems like a lot of work and I wouldn't want to have to manually maintain both sets of ToCs since we're trying to make PDF and HTML versions of the same content. I could also add those sorts of items to the existing ToC, but would that affect the PDF output at all?

Additionally, we could change our basic organizational structure from snippet-based to topic-based, so the *.fltoc files would have to look like what I expect the generated Contents to look like, but the amount of work involved in that method is daunting. I'm hoping that's not the right answer.

I was also looking at the possibility of using a browse sequence (which looks like it should be able to be automatically generated) but I'm not sure if that's the best answer, either. Is there some other way to change the generated Contents in HTML5 output that I'm not aware of?

Any thoughts on how to best approach this problem? Thanks in advance!
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Can you make the HTML5 ToC look like PDF Bookmarks listing?

Post by NorthEast »

As you've probably figured out, the HTML5 (and all web targets) contents displays exactly what's in your TOC (*.fltoc) file, and the print TOC proxy in your PDF is generated from heading levels in your topics (based on styles with the mc-heading-level property).

(I'm not a fan of this either - I don't understand why there are two entirely different mechanisms, for what is supposed to be a single-sourcing tool.)

Anyway, I'm presuming your PDF contents is showing the sub-headings inside topics; and you want these to also appear in the HTML5 contents?
(As opposed to having the PDF output match the online TOC, which is a different answer.)

To include heading-levels inside topics in the HTML5 contents:
1. Select all TOC items in the TOC editor.
2. Open the properties for the TOC items, move to the Auto-generate tab, select Compute Sub-entries from linked file, choose Replace with computed entries, and select the Depth required.

Help: http://webhelp.madcapsoftware.com/flare ... %20entries
mlaird
Propeller Head
Posts: 49
Joined: Wed Feb 06, 2013 3:18 pm

Re: Can you make the HTML5 ToC look like PDF Bookmarks listing?

Post by mlaird »

Ah, excellent. Yes, that's exactly the sort of option that I was looking for. Thank you, that is vastly preferable to the other solutions I was considering!

I'm in agreement with you about being a bit puzzled at how differently ToCs behave for different outputs, though.

Thanks again.
johnnygreen
Propeller Head
Posts: 30
Joined: Wed Sep 12, 2012 4:25 am

Re: Can you make the HTML5 ToC look like PDF Bookmarks listi

Post by johnnygreen »

I work for a company that would like to see the chapter and section numbers in the HTML5 TOC as well as in the PDF bookmarks (strange I know), and I thought I'd found the 'silver bullet' with the following:

To include heading-levels inside topics in the HTML5 contents:
1. Select all TOC items in the TOC editor.
2. Open the properties for the TOC items, move to the Auto-generate tab, select Compute Sub-entries from linked file, choose Replace with computed entries, and select the Depth required.

However, I feel thwarted by Flare once more. All the above does is generate only Level 1 headings and topics in the HTML5 output, no matter what 'Depth' is selected above. The Heading 1 topics are nicely numbered as per the PDF bookmarks - it's just a shame I don't get the rest of the heading levels! Is this any sort of known issue?

I am using Flare 10 and have Headings Levels 1-5 numbered correctly so that the correct numbered bookmarks are generated in the PDF.
johnnygreen
Propeller Head
Posts: 30
Joined: Wed Sep 12, 2012 4:25 am

Re: Can you make the HTML5 ToC look like PDF Bookmarks listi

Post by johnnygreen »

As a further thought, if I can persuade them to drop all chapter and section numbers from the HTML5 online help, how would I ensure that the chapter and section numbers only appeared in the PDF, as the Non-Print Medium does not allow me to remove the numbering?

OK, I've worked this one at least - you enter '{ =0}' as the heading style in the non-print medium version of the stylesheet.
Post Reply