Re: [Boost-docs] [auto-index] Generating an index in PDF output

Subject: Re: [Boost-docs] [auto-index] Generating an index in PDF output
From: Edward Diener (eldiener_at_[hidden])
Date: 2011-01-26 14:27:06


On 1/26/2011 4:53 AM, John Maddock wrote:
>> In my doc jamfile I have:
>>
>> <auto-index>on
>> <auto-index-type>appendix
>> <auto-index-script>index.idx
>> <auto-index-prefix>../../../
>> <auto-index-verbose>on
>> <format>html:<auto-index-internal>on
>> <format>html:<xsl:param>generate.index=0
>> <format>pdf:<auto-index-internal>off
>> <format>pdf:<xsl:param>index.on.type=1
>> <quickbook-define>enable_index ;
>>
>> I am getting an index in my HTML output but I was not getting one in
>> my PDF output. So I changed to:
>
> PDF output with <format>pdf:<auto-index-internal>off works just fine for
> me here (latest sandbox source).

It works fine but I get no index entries in my pdf output, just an empty
Index section. In the auto-index output it is definitely picking up the
entries from the scan. In the HTML output I do see the Index entries.

My command line is:

bjam --enable-index --boost=C:/Programming/VersionControl/boost
toolset=msvc-10.0 pdf

It is true that I get no Index items in PDF even when I comment out the
line in my jamfile which says:

# <auto-index-type>appendix

>
>> <format>pdf:<auto-index-internal>on
>>
>> but now the output says:
>>
>> fop.render.pdf
>> ..\..\..\bin.v2\libs\tti\doc\msvc-10.0\debug\auto-index-internal-on\auto-index-verbose-on\auto-index-on\threading-multi\TypeTraitsIntrospection.auto_index.pdf
>>
>> (document [system-id
>> file:/C:/Programming/VersionControl/sandbox/tti/libs/tti/doc/../../../bin.v2/libs/tti/doc/msvc-10.0/debug/auto-index-internal-on/auto-index-verbose-on/auto-index-on/threading-multi/TypeTraitsIntrospection.auto_index.fo]
>>
>> (validate
>> [error] Element 'fo:page-sequence' cannot be a child of 'fo:flow'.
>> Only block-level elements are permitted in this context.
>> [validation total: 1 error]
>> Parse error: Invalid XSL FO source
>> 'file:/C:/Programming/VersionControl/sandbox/tti/libs/tti/doc/../../../bin.v2/libs/tti/doc/msvc-10.0/debug/auto-index-internal-on/auto-index-verbose-on/auto-index-on/threading-multi/TypeTraitsIntrospection.auto_index.fo':
>> 1 error found during validation
>
> Grrrr, I think this is because of your quickbook document type - the
> outermost XML element in your doc is "chapter", but then you set
> <auto-index-type>appendix which tries to place an appendix *inside a
> chapter* which is not valid Docbook XML. Depending which stylesheets get
> invoked this may end up working OK by mistake as it were, but some
> combinations produce invalid FO XML which XEP then flags up.
>
> So to conclude, it appears you can't mix:
>
> [library The Type Traits Introspection Library
>
> with an appendix, because "library" creates one chapter of a book, which
> can't contain an appendix.
>
> So either change the document type, or don't try and use an appendix.

I made the type 'library' because tti is a library. I notice 'library'
is designated for other Boost libraries like Type Traits.

If I do not use appendix, then how can I get the index to appear at the
end of my documentation on a separate page ? Or is it not possible to do
this once my document type is 'library' ?


This archive was generated by hypermail 2.1.7 : 2017-11-11 08:50:41 UTC