Apache OpenOffice (AOO) Bugzilla – Issue 26450
Improve options for including paragraph text in Table of Contents
Last modified: 2014-04-09 09:57:02 UTC
Writer, by default, includes all paragraph text in TOC entries. This produces a cluttered TOC if you want to include some detail of the document in the TOC. For example, a three-tiered document constructed of: Main Headings - centered, bold, all capitals; Section Headings - left justified, bold, no font effects; and Paragraphs - left justified, normal text, with a paragraph heading and paragraph numbering. produces a TOC like this: FirstMainHeading.....................................................................2 FirstSectionHeading................................................................ 2 1.Para1 Title. This is the text included in the body of the paragraph. This is the text included in the body of the paragraph. This is the text included in the body of the paragraph.............................................................................2 which is fine except for *all* the text from para 1 being included in the line for its listing. For better illustration, the first attachment shows a sample document with this effect. The desired output is: FirstMainHeading.....................................................................2 FirstSectionHeading................................................................ 2 1.Para1 Title.............................................................................2 For better illustration, the second attachment shows a sample document with the desired TOC. It also shows what the TOC would look like if the clutter was avoided by not including the paragraphs (the third tier) in the TOC specification. That listing is so devoid of information to be hardly useful. A worthwhile improvement to the TOC feature would be if users could choose the text from each paragraph to be included in the TOC. This could be done by formatting the desired text with a particular Character Style and including a selection box in the TOC dialog to pick the Character Style - for each level - that will define the included text. For example, my attachments have all their paragraph headings given their style through the 'ParaHeading', Character Style. The suggested improved TOC feature would see the TOC generator include, for level 3 in this example, only that paragraph text formatted as 'ParaHeading' and omit the rest, to give the output seen in the second attachment. If a paragraph did not have any text formatted with 'ParaHeading', then it could be left out of the TOC listing. Paragraphs which did not have this selection enabled would have all their text included - as would be appropriate for most main or section headings. The addition to the TOC dialog would be a check-box, followed by a drop-down Character Style selection box implemented for each outline level, thus: [box] Define included paragraph text? [Character Style drop-down box] (ghosted until the 'Define included paragraph text' box is checked. This sort of improvement is necessary, as the attachments show. As things stand, the TOC either contains insufficient information, or is too cluttered to be of any use.
Created attachment 13778 [details] Example document showing cluttered TOC
Created attachment 13779 [details] Example document showing the desired TOC
Sorry, the examples have been clobbered by site formatting. Better ones follow (hopefully). Cluttered TOC: FirstMainHeading............................................................2 FirstSectionHeading........................................................2 1.Para1 Title. This is the text included in the body of the paragraph. This is the text included in the body of the paragraph. This is the text included in the body of the paragraph....................................................................2 Desired TOC:: FirstMainHeading............................................................2 FirstSectionHeading........................................................2 1.Para1 Title....................................................................2
You can get such a TOC when you mark the "in line"-heading and define it as index-entry (Insert - Indexes and Tables - Entry). There you choose the Index "Table of Contents" and Level "3". In the TOC itself check the option "Index Marks". Automatically including in line headings via style would mean, that there had to be an option in the TOC to recognize character-styles. I don't think that such an option is really necessary.
Thanks for the suggestion Regina. I tried it, but it didn't work for me. I *did* get the paragraphs as I wanted, but they were displayed *in addition* to the original ones (ie, doubled-up). To get rid of the duplication, I would have to remove the check marks from 'Outline' and/or 'Additional styles'. That would mean having to create index references for the other headings manually with the 'Entry' option, when they are already created automatically for me at the moment. For that reason, I don't think it would be a practical solution. For the example I gave, I would have to create 18 index marks, as well as those for all the main and section headings. This would not be practical for a large document. Indeed, it would be similar to the problem facing those having to insert many cross-references in their documents. A more practical solution is as I have suggested: the desired text in the paragraphs has already been marked by the Character Style, all that is needed is the selection in *one* place for them to be used as the TOC text. After all, I have a computer - it should be doing the work for me, not the other way around.
> but they were displayed *in addition* to the original ones Oh, I didn't mentioned, that in "Additional Styles" you have to move your "ParaNum" to the column "Not applied". But handling should be discussed in one of the user mailing lists, not here.
Thanks again Regina. That removes the problem of having to designate included text for every main and section heading, but not for *every* paragraph; the original shortcoming stands and needs attention. I have responded to your comments to add to the dabate here on the TOC feature in OOo Writer, not to receive or give advice on how this word processor should be used. The person who investigates this request for enhancement needs to understand why the present method is such a pain, and why improvement is needed. In this context, 'handling' is a legitimate discussion here. 'Handling' is the essence of getting an application's GUI right, which in this particular case, is not quite right. And anyway, I don't use mailing lists, which are an obsolete communications paradigm; I use the modern equivalent - the website forum.
I've just tried Regina's suggestion on removing 'ParaNum' from the 'Additional Styles' section, and have found the TOC to appear uncluttered, but all paragraph numbering has been removed from the TOC listing for level 3. To fix that requires more manual configuration that involves removing the ParaNum1 Numbering Style from the ParaNum Paragraph Style, then implementing numbering through Tools->Outline Numbering. *Then* paragraph numbering does not continue sequentially throughout the document; it re-numbers from '1' after each intervening style that is *not* ParaNum (including MainHeading and GroupHeading). Sigh! So, in short, this is not a practical solution. The 'automatic' solution I suggested is just begging.
reassigned to bh
To grep the issues easier via "requirements" I put the issues currently lying on my owner to the owner "requirements".
Confirmed with AOO410m14(Build:9760) - Rev. 1585624 2014-04-08_04:11:10 - Rev. 1585644 Debian