Hi all,
I am working in Flare (v12) and trying to figure out a way to do something in the TOC that is, perhaps, uncommon. I want a few topics (they, like the other topics, have h1 headings) to appear at the beginning of the TOC, before the page-numbered sections, but not have any page numbers (or leaders) nor do I want them to be counted as pages for numbering. Is this possible?
My output will be to PDF. Any help that can be offered is greatly appreciated because I am banging my head against the wall on this one.
Suppress the page numbering on some items in TOC?
Re: Suppress the page numbering on some items in TOC?
What you probably really want to do is define a class on the H1 tag which goes into a modified TOC entry style which does not have the page number. But it doesn't work that way. There are just 9 TOC level styles and the mc-heading-level determines which one you get.
So another idea is to make the H1 class set these to some unused heading level, i.e. mc-leading-level="9", and configure the p.TOC9 style appropriately. But if you use PDF bookmarks, this will mess them up. IIRC, it will create empty bookmarks for the missing levels to place these entries down at level 9.
So the real solution, I think, is to suppress these entries from the TOC entirely and fake their TOC entries.
If you have not already done so, create a TOC topic for your PDF output and put a TOC proxy into it, instead of letting Flare do it itself with the Generate TOC proxy option on the Advanced tab of your target.
This TOC topic should have the heading you want on the print TOC and a TOC Proxy object (which you can find under the Insert | Proxy menu).
In the help TOC which defines the structure of this output, be sure that you place the TOC proxy topic into the appropriate place. It may look like the following (this also assumes you use an index proxy in the same manner):
Title Page
Copyright Page
Contents (Proxy)
special topic 1
special topic 2
...
normal topic 1
normal topic 2
...
Index (Proxy)
If you are generating help from this project, be sure to tag the TOC entry and the TOC proxy topic itself for print only.
Now, in your stylesheet create a class on the H1 tag such as H1.unnumbered. Give it mc-heading-level="0", and in the special topics, set this style on the H1 tag. This 0 tells Flare not to create entries in the print TOC or PDF bookmarks for these headings.
Create another style in your stylesheet, perhaps called p.TOC1fake, which copies the normal style properties (i.e. Font, Block, Box groups) from p.TOC1. In your TOC proxy, create paragraphs in this style before the TOC Proxy object to make fake entries for the special topics. Make them be hyperlinks to the topics if you want that.
To fix the pagination, in the help TOC, right-click the first TOC entry after the special ones, click Properties, and on the Printed Output tab, under Page Number, select Reset to, 1, decimal (or whatever is appropriate for your manual). This will ensure that the pages occupied by the special topics do not count as pages for numbering. In the entries for the special topics, on the Printed Output tab, select Break Type None. This would make the special topics use the same page layout and numbering that you've set up for the contents section. If you need something different, you can set up a separate page layout (maybe a copy of the page layout used for the regular content, with the page number removed) and use a Page Layout Break on the first special topic to switch to this page layout.
So another idea is to make the H1 class set these to some unused heading level, i.e. mc-leading-level="9", and configure the p.TOC9 style appropriately. But if you use PDF bookmarks, this will mess them up. IIRC, it will create empty bookmarks for the missing levels to place these entries down at level 9.
So the real solution, I think, is to suppress these entries from the TOC entirely and fake their TOC entries.
If you have not already done so, create a TOC topic for your PDF output and put a TOC proxy into it, instead of letting Flare do it itself with the Generate TOC proxy option on the Advanced tab of your target.
This TOC topic should have the heading you want on the print TOC and a TOC Proxy object (which you can find under the Insert | Proxy menu).
In the help TOC which defines the structure of this output, be sure that you place the TOC proxy topic into the appropriate place. It may look like the following (this also assumes you use an index proxy in the same manner):
Title Page
Copyright Page
Contents (Proxy)
special topic 1
special topic 2
...
normal topic 1
normal topic 2
...
Index (Proxy)
If you are generating help from this project, be sure to tag the TOC entry and the TOC proxy topic itself for print only.
Now, in your stylesheet create a class on the H1 tag such as H1.unnumbered. Give it mc-heading-level="0", and in the special topics, set this style on the H1 tag. This 0 tells Flare not to create entries in the print TOC or PDF bookmarks for these headings.
Create another style in your stylesheet, perhaps called p.TOC1fake, which copies the normal style properties (i.e. Font, Block, Box groups) from p.TOC1. In your TOC proxy, create paragraphs in this style before the TOC Proxy object to make fake entries for the special topics. Make them be hyperlinks to the topics if you want that.
To fix the pagination, in the help TOC, right-click the first TOC entry after the special ones, click Properties, and on the Printed Output tab, under Page Number, select Reset to, 1, decimal (or whatever is appropriate for your manual). This will ensure that the pages occupied by the special topics do not count as pages for numbering. In the entries for the special topics, on the Printed Output tab, select Break Type None. This would make the special topics use the same page layout and numbering that you've set up for the contents section. If you need something different, you can set up a separate page layout (maybe a copy of the page layout used for the regular content, with the page number removed) and use a Page Layout Break on the first special topic to switch to this page layout.
Re: Suppress the page numbering on some items in TOC?
Yes, I actually was exploring the first two options... but I can now see by your reply that either of them are unlikely to work properly. I understand why the first one doesn't work, but I am a little bit hazy on understanding the reason for the pitfalls of the second (to the point, I am not sure what would happen with the PDF bookmarks). However, the third option seems like it might be a solution. It seems very roundabout, am i the only person who has ever had the idea to this sort of thing on a TOC in Flare? 
-
Daniel Ferguson
- Propeller Head
- Posts: 77
- Joined: Wed Jul 10, 2013 12:34 pm
- Location: Salt Lake City
- Contact:
Re: Suppress the page numbering on some items in TOC?
You can use the mc-pagenum-display property in the stylesheet to remove the page number and leading from TOC levels. For example, if you wanted the h1s to show up without page numbers in the TOC, you could put this in your stylesheet:
Not sure this solves the entire problem, but it might be a start.
Code: Select all
p.TOC1
{
mc-pagenum-display: none;
}