DITA and XMetaL Discussion
XMetaL Community Forum › DITA and XMetaL Discussion › TopLeaf: map.dtd does not generate Index with DITAmap-Template
-
[email protected] July 25, 2011 at 4:33 pm
TopLeaf: map.dtd does not generate Index with DITAmap-Template
July 25, 2011 at 4:33 pmParticipants 6Replies 7Last Activity 11 years, 8 months agoContent marked with
does not convert into index entries using the DITAmap-template in TopLeaf if the dita map is using the map.dtd (as opposed to the bookmap.dtd). No index is generated at all for maps using map.dtd. In a bookmap.dtd, the
is generated, and TopLeaf if using to kick off the perl script to build the index. does not get generated with map.dtd, so not sure what should be used to kick off the perl script. (When the XMetaL Enhanced PDF via Renderx XEP ouput is selected (not TopLeaf) for a map.dita file, an Index is generated without the use of
, so not sure how that's done, and if it would be similar to getting an Index for a dita.map in TopLeaf…) What's the fix?
Thanks,
RP
gjn2066 August 30, 2011 at 12:39 am
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
August 30, 2011 at 12:39 amHmmmmm, I'll try this myself and get back to you.
[email protected] September 12, 2011 at 4:15 pm
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
September 12, 2011 at 4:15 pmIt's not valid DITA, but I found that if I insert
before the closing , an Index [u]is generated[/u] based on the s throughout the DITA Map's topics when using the map.dtd. There's no heading for it in the TOC however, but the Index is complete and accurate. This also works for
when the additional %FigureListEntry markers etc. are added (per Murray's recipe). It's a possible workaround, but would prefer automatic generation of the Index without having to make the DITA Map invalid.
RP
gjn2066 September 20, 2011 at 5:06 am
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
September 20, 2011 at 5:06 amYou've almost got it. While you can't/shouldn't put an invalid
[u]element[/u] in the source, you can/should put an [u]custom marker[/u] in the map mapping Post-content. All you need do then is create the %IndexList mapping based on (ie. copied from) the indexlist tag mapping.
You can then modify tl:ndx to generate a ToC entry.
[email protected] January 10, 2012 at 9:34 pm
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
January 10, 2012 at 9:34 pmYou can then modify tl:ndx to generate a ToC entry.
How exactly is that done on the tl:ndx Content tab? I've selected Scan element content, then selected Assign to TOC level (2), and Set Target ID from attribute (id), and then regenerated, and the entire Index, all entries/terms, appears in the TOC. Do I need to set something on the tabs for %IndexList as well?
Thanks!
RP
gjn2066 January 11, 2012 at 12:16 am
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
January 11, 2012 at 12:16 amBasically whatever you scan goes into the ToC. So if you scan the whole index, then that's what you get.
What you need to do is to just scan the word Index. This is where Custom Markers come in. As you know a CM is simply an XML “element” defined on the fly during the typesetting, and which can be used in the Pre/Post-content of normal elements.
So in your tl:ndx Pre-content just add the following:
Index then define your %IndexHead mapping to scan and assign to ToC.
Note that while a CM can have its own Pre/Post-content, in this case you can't simply say
, since there is then no content to scan/assign. Note that if you already have a CM for creating ToC entries, you can use this instead of IndexHead.
[email protected] April 9, 2013 at 7:26 pm
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
April 9, 2013 at 7:26 pmI'm revisiting this again, and still not able to get the Index to generate.
- In the
- I've created a %IndexList custom marker based on the
mapping with {L-Index} in the Pre-content, and Scan element content and Assign to TOC level 1 on the Content tab. - On the tl:ndx mapping, I've added
Index to the Pre-content
… but still no index entries.
A bit lost (again)…
Thanks,
Robert
tonys April 10, 2013 at 9:13 pm
Reply to: TopLeaf: map.dtd does not generate Index with DITAmap-Template
April 10, 2013 at 9:13 pmAre you seeing the “Index” title on an otherwise empty page, or do you get nothing at all?
The debug log should help you find out what is going wrong. You'll need to use the workstation interface to do this – both to make sure debugging is enabled and to access the log.
If you see a title but no index entries, check that the “indexterm” mapping is being called.
If you haven't made a lot of your own changes, I would recommend looking at the new stylesheets that are supplied with the latest version of TopLeaf and also using the latest plugin. The DITAmap stylesheets had quite a few problems, such as the different treatment of map and bookmap.
- In the
-
AuthorPosts
- You must be logged in to reply to this topic.