Table of contents - paragraph merge turned off - bg color still merges

I have set a border around the top level entries in the table of contents for a book. I found that when two top level headings appeared in series, that they only had one border. It did not look good, but then I found a setting in the styles in the border tab ‘merge with next paragraph’ and unchecked it. Big sigh of relief, the borders are now separate! --ah but ut oh, the background color that is to be limited to within the borders now flows out of the borders and still merges … yuk. Also, note that line widths are inexplicably narrowed at the bottom (I can deal with this, but still). Note attached screen shot. Notice the yellow coloring between the two heading entries where one would expect a white gap. How to a stop the color from merging like this? There should be a gap between the heading entries. Thanks

Hi

I reproduce the problem on my platform (windows 7/64 & 5.2.4.2).

I’m not sure we can talk about a bug. This seems to me more of a limitation: it lacks the “do not merge” property for the background color (as it exists for borders).

That said, I can propose you the following workaround:

  • Create a character style that applies the background color (e.g. Title in this example MergeTitle.odt)

  • Edit the index to affect this style to entries: Entry Text and Tab stop (E & T)

Regards

There’s no “merge” for area fill, because it doesn’t make sense.

Borders is set of lines that are drawn with an offset from characters, and visually separates the contents from outside. It makes sense sometimes to modify the behavior that it merges adjacent borders, so that a number of paragraphs share one common frame.

But that’s not like that in area fill. There’s paragraph area; it includes top/bottom spaces and it is filled. It doesn’t merge with next; just no space between them.

this doesn’t make sense to me, as note the yellow background stops at the border for the second heading one entry. The problem only occurs when two heading ones appear together. So area extends beyond borders as a function of what the next format is? Then that is a merge.

There’s no “area extending beyond borders”, area is completely separate from those borders. But area is computed using some complex rules. And there’s no “merge” here. On bottom level, page consist of a series of adjacent areas representing different entities (paragraphs, tables, etc) without any gaps between them (i.e. their spacings are counted as part of that entity area).
I can’t say for sure what your paragraph settings are for both level 1 and level 2 ToC paragraphs without actual document

Yes, this works. The highlighting color set for the new character style is pale yellow. I think had it been a different color the narrow gap of white between the highlighting and the border, as you can see in your example above, and as appeared when I did it, would be a problem. But for pale yellow it looks ok. Thank you. This is a creative work around.

Hi Mike, well, fact is, when two top level contents are put together the yellow background goes outside the borders. This behavior does not occur elsewhere. It is also undesirable behavior. I can’t think of a case where I would want my background color to go outside the border lines, and it certainly doesn’t work here.

You are welcome to file an enhancement request about it.

If you can’t think of a case where something could be helpful for you, doesn’t mean no one else can’t about their use cases. But any constructive proposal is great.

The Area color is not limited to characters area, it covers all area that paragraph takes (including spaces above/below).

What you possibly want is Highlighting color?

So why does the paragraph area for the first heading one extend below the border, but it doesn’t for the second heading 1? Or analogously, if one scrolls further down the index, why does heading one extend above the border when the prior paragraph style is heading 2, but it does when the prior paragraph style is heading 1. Obviously it is doing something different when two heading 1 paragraph styles are placed adjacently than it is doing when they are not.