DITA and XMetaL Discussion

XMetaL Community Forum DITA and XMetaL Discussion Truncated topic titles in the ToC

  • Scibert

    Truncated topic titles in the ToC

    Participants 3
    Replies 4
    Last Activity 10 years, 1 month ago

    Topic titles in the ToC are sometimes truncated and suffixed with an ellipsis (…). I found that if a topic title contains more than 10 words, it is truncated. However, this rule is circumvented by the presence of punctuation marks.

    The attached sample contains three files: two DITA topics and a map. If you open the map in XMetaL, you'll notice that first topic appears as “One two three four five six seven eight nine ten…” whereas the actual topic title is “One two three four five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen eighteen nineteen twenty“. However, the second topic, which contains punctuation marks (commas), is displayed in its entirety.

    If there's anything I can do to somehow let all topic titles display in their entirety (without any truncation) in the ToC, please let me know. Otherwise, modifying the program on your end would greatly be appreciated.

    Reply

    Derek Read

    Reply to: Truncated topic titles in the ToC

    When you “Refresh References” on a map (F11, or possibly when the map is opened depending on settings in Tools > DITA Options) it populates the @navtitle for (by pulling in the text from the topic's ) and then displays that value using a CSS :before selector. This feature is working as designed since when @locktitle is not set or it is set to “no” the @navtitle is not supposed to be used for output. Refresh references in this case is populating the @navtitle as a “navigation aid” (to help you author your map) and truncating the text is also by design (questionable perhaps, as I don't see the real benefit, but it was done on purpose).</p> <p>So, the real problem here seems to be that WebHelp output is not respecting @locktitle. It is only when @navtitle is set to “yes” that output processors (like the DITA OT) are supposed to use @navtitle. When it is not set, or set to “no”, then @navtitle is supposed to be ignored and the content of the topic's is supposed to be pulled in. If you compare the “Multiple HTML files” deliverable with “WebHelp” then you will see what I mean as it will put the proper text into its ToC page.</p> <p>The fix would need to be done in the WebHelp plug-in. I'll file that as a defect.</p> <p>I can't think of any good workarounds that include modifying your content. The only one that might work would be to set @locktitle to “yes” and then put the full title into @navtitle (this isn't really 'good' but perhaps not too harmful). However, then you'd need to remember you locked these titles and to update them if you modify the in the corresponding topic. Alternatively, you could dial down the “refresh references” feature and then leave @locktitle unset, but then also manually modify @navtitle. The only benefit here is that you could then fully enable refresh references again if you made changes to get modified titles pulled in so that you can more easily identify them (at which point any long ones would need to be manually fixed again).

    Reply

    Scibert

    Reply to: Truncated topic titles in the ToC

    Hi Derek,

    Thanks for logging this as a defect. Looking forward to the fix in the next release (or patch file(s), ideally, for time's sake).

    Reply

    jlm05

    Reply to: Truncated topic titles in the ToC

    I've run into something similar, where XMetal inserts ellipsis at the end of longer topic titles in the WebHelp TOC, although in most cases it isn't actually truncating the text.

    For me, if I change locktitle to “No” instead of “Not set”, then the title displays without the ellipsis.

    Janice

    Reply

    Scibert

    Reply to: Truncated topic titles in the ToC

    Hi Janice,

    Thank you! Setting @locktitle to “no” solves this issue. This is exactly how titles should be rendered by default when @locktitle is not set.

    However, please note that setting @locktitle to “no” solves this issue, but only temporarily; XMetaL automatically truncates and re-adds the ellipsis to long topic titles when the map is re-opened or refreshed. This is still a bug.

    Reply

  • You must be logged in to reply to this topic.

Lost Your Password?

Products
Downloads
Support