How to solve particular list need in style with features

Unless you want the book title in the TOC, Heading 1 is intended for chapter headings. Book title has a dedicated paragraph style named Title.

Checking and debugging your sample file was quite long. See my (lengthy) answer and study the revised sample.

First of all, I thank you for the time you have dedicated to me, but I suggest you limit yourself to the problem I am presenting to you, don’t look at everything, it’s not necessary. Regarding the setting of the first page, for example, I’m not interested in defining a style that I use only once in all book, I do it manually without styles. Maybe some things I will understand in the future, I have only been using Writer for a few weeks.

I downloaded your attached file a few hours ago and I have to tell you that even now I don’t understand how you managed to create 4.A and 4.B after 3. I can’t reproduce it in my book.
Looking at my sample file, actually I need that after 3 there are 3.A and 3.B (not 4.A and 4.B), then start over from 4. Probably, your trick with the invisible paragraph (regesto invisible) is not needed because you are hiding 4, which I didn’t ask.

if you pay attention to my sample file, you will find that in your sample file there are things doesn’t work as I want…

I add this comment to clarify that I appreciate your help, but in my opinion you should review what you’ve done, because in my sample file (with poor settings but works for me) I’ve achieved results that I don’t intend to lose. Please, restart from my sample and solve only point 4, rest is ok.

Let’s go in order.

  1. In standard TOC called “Indice” you have entered the links that I don’t want.

  2. In TOC called “Indice dei regesti” I must have a trivial list made like this:

    1. summary act #1
    2. summary act #2

      (You have reviewed this TOC and introduced links that I don’t want)
  3. Each act description is preceded by a few lines with a gray border on the left. You have entered a space, the border isn’t continuous as before.

  4. I asked you to have act 3A and 3B (or 3.A and 3.B is fine) after act 3 and before act 4. Therefore I must have in sequence 1, 2, 3, 3A, 3B, 4, 5 but you created …3, 4A, 4B, 5

  5. Alphabetical index called “Indice dei luoghi” no longer works.

  1. I didn’t intentionally modified your “indice” TOC. This is likely the consequence of my investigation when I righ(-clicked on it to Edit Index. My default settings may have done this addition. Apologies.

  2. I did extensive changes in “Indice dei registri” and again I suppose my default settings came into play.

It is quite easy to fix: delete LS and LE in the structure lines.

However, are you sure you didn’t create the hyperlinks? I downloaded again the sample file and the hyperlinks are already there. This may be a by-product of the preparation of the sample file on your side.

Point 3

Border merging is quite erratic in Writer. It looks like border attributes are not well inherited by dependent styles (thanks for making me learn this aspect). The slightest difference in the settings causes the borders to be separated by a non configurable space.

I worked again on the styles and the issue is fixed. Due to this unspecified behaviour, you need to tune both Sommario regesto and Riferimento atto, though the latter is a descendant of the former (adjusting the border in the ancestor should be sufficient). I think this is a bug. I’ll report it when I have time to characterize it.

Point 4

Your specification was not clear on this requirement and I didn’t understand the act numbers. Your sample has an act 3 and requests creation of acts 55a and 55b.

Anyway, I just remove the dummy hidden paragraph and this should give what you intend.

By the way, enable View>Formatting Marks and Tools>Options, LibreOffice Writer>View Hidden text and Hidden Paragraphs in Display fields to be able to see on screen (it does not change printing) the tricky formatting if you haven’t yet enabled them.

Point 5

This is the most difficult issue. The changes I made to “normalize” formatting and act numbering removed Sommario regesto from Tools>Chapter Numbering and the act number could no longer be captured.

I modified Sommario regesto to set it under Tools>Chapter Numbering control (I assigned it to level 8, not knowing if you use levels 3+ for subchapters; it is easy to change). Unfortunately, unlike lists, you can’t assign the same paragraph style to several levels. I then recreated *Sommario regesto (2nd level) for the 9.Z acts and assigned it level 9.

But inserting your Sommario xx in the chapter numbering hierarchy has a bas consequence for you: you can’t uniquely number the acts. The number is reset whenever you switch to another chapter. As an example I added an act in “Protocollo 2”. Its automatic number is 1 because “Protocollo 2” is a Heading 2 which causes all higher Heading n to reset.

(to be continued)


The solution is perhaps to invert my initial proposal: keep your acts in Tools>Chapter Numbering, at levels 1 & 2, i.e. Heading 1 and Heading 2 now and use specific paragraph styles which an associated list style (Numbering 1) for your chapters and subchapters. These paragraph styles are assigned an outline level so that they are captured in the TOC.

Updated sample file (without this last proposal which implies a restyling of your chapter headings and a reconfiguration of your various TOCs – but this is quite fast).

I’m looking at your latest file, it’s almost perfect.
Hyperlinks can be handy, so I keep them, but I want to hide them because you don’t want to see any blue text or underlined text in the book. Therefore, I believe that the right solution is to change the style called Internet Link. Did I act correctly?
I have also modified the Indice dei regesti to match my tastes.
Look at my edits from your last file. sample for forum 2.odt

There is only one thing left to fix. The first act of Protocollo 2 must have the number 5 and must resume the numbering terminated in the previous chapter (Protocollo 1). Does your system allow me the opportunity to (manually) jump from act # 7 to act # 10? Or should I create them and make them invisible?


I don’t understand how the hyperlinks are highlighted. There is no such thing on my side. Maybe a screenshot may help

Continuous act numbering is possible but I need to think about it. The difficulty comes from the fact you are trying to use a single numbering sequence (Tools>Chapter Numbering) for 2 independent “collections”: chapters and acts. Formally two list styles are needed, but as you noticed there are “glitches”. If your alphabetical index only ever references act numbers and no chapter number at all, it is possible at the cost of a “dirty trick”. I experiment and report back here.

Autonumbering is continuous. You can’t have holes in the sequence. At best, you can restart at one. So, as you guessed, the solution is to insert hidden items. I hope you don’t need to jump from 12 to 345.

my new sample file

In my previous comment I wrote that the solution to be adopted for hyperlinks is to change the Internet Link style. I think I was wrong, because the solution to choose is to modify and edit the index and apply Default style to the entries (E).

I will create two alphabetical indexes (now you see only one) that collect different types of items, but both refer only to act numbers (I confirm) .

I configured the styles for your purpose but there is still a problem.

I removed Heading 1-3 from Tools>Chapter Numbering. It looks like you don’t use auto-numbering: Introduzione is not numbered and Protocolli are manually numbered. They are now at outline level Text Body. Since you “manually” collect your outline with Assign Styles, the main TOC is not changed.

Sommario xx are at chapter numbering 1 and 2. They are collected as “standard” TOC in “Indice dei regesti”. I took the liberty to slightly alter the structure and customised Contents 1 and Contents 2. CAUTION! these changes also apply to the main TOC. I suggest you assign separate styles to both TOCs so that you can tune one without messing the other.
Alphabetical index is unchanged.

The non-continuous numbering seems to be caused by some internal bookmark set by LO. I had to type a fresh #5 before the faulty 1 and delete it.

The remaining problem is the page header.

(to be continued)

[…] By exchanging the roles of Sommario xx and Heading n field Document>Chapter points now onto Sommario which is not what you want. If there are not too many chapters, you can create one page style per chapter so that you can have a different header content.

As you already manually force page breaks between chapters (instead of creating them automatically from Heading 2 paragraph style in Text Flow), I think it does not matter.

In order to insert a cross-reference to chapter heading, the heading must be numbered. Thus I associated Heading 1-2 with Numbering 123. The exact formatting of the list item is not important because it will not be displayed. Its character style os Invisibile. But the hidden attribute is not taken into account (perhaps yet another bug). So I set font size to 2 pt (the absolute minimum) and transparency to 100%. I needed to modify the main TOC structure line to avoid showing this number.

I inserted a cross-reference to “Protocollo 1” in …

… the first chapter and let you create the required pages styles for the other chapters.

Here is the revised sample file

I saw your latest file. Thank you for your latest technical explanations, but maybe some details I don’t even notice. What is important to me are two things.

  1. make the best use of the program’s features to meet my particular needs;
  2. once the book is printed (I can already see it in the print preview) it must look exactly how I want it.

So, let’s go to the last two problems (I hope) I’ve seen.

  1. I inserted some test acts and unfortunately I noticed that “Indice dei regesti” TOC also shows the acts to which I have assigned the invisible style. Therefore I guess the invisible style only works on the main text.
  2. In the header of the left page I have to show the book title and I am using the Title property, as you suggested. In the header of the right page I have to show the title of what I consider chapters, those that in your file reflect Numbering 123 (level 1), for example “Protocollo 1”. Before with the chapter field it was possible, now I don’t know how to do it.

As your questions are becoming more and more targeted to your work and less general, I suggest we continue privately. Contact me at ajlittoz (at) users (dot) sourceforge (dot) net. As soon as we’ve made a handshake mail exchange, you’ll have my real email.

Automatic lists is the most difficult feature to configure in Writer because it involves two style categories: a paragraph style and a list style (in fact a counter definition). But, once set up, you no longer use the list button, otherwise you mess up your setting.

You already have defined your Summary **paragraph style. You must associate it with a counter. Open your Summary definition and go to the Outline & Formatting tab. In section Numbering, select from Numbering style drop-down menu Numbering 123. OK

This has the effect to assign the Numbering 123 list style to your Summary paragraph style.

Every paragraph so styled will have automatically a list item number.

To tune the formatting of the items (with regard to indents), you must modify the list style and not the paragraph style because the list style settings take precedence over those of the paragraph style. List styles are listed in the side style pane (F11 if not yet visible) by clicking on the fifth icon in the toolbar.

Right-click on Numbering 123 and Modify. The settings are in Position and Customize tabs.

CAUTION! Don’t play with BulletsImage tabs because they ruin what you have set in the aforementioned tabs and you’ll have to start over again.

How to use Summary?

When you want to type a list item, just style the paragraph Summary. Don’t use the list button.

If you follow the recipe above in an existing document where you have already Summary paragraphs with List button added, remove first the effect of the List button otherwise Writer will get confused and you won’t be able to format your list.


Numbering 123 is now associated with Summary and should not be used with other paragraph styles. Numbering 123 defines one list; So unless other paragraph styles are only stylistic variations of Summary intended to be part of the same list, avoid multi-association or you’ll be disconcerted by the result.

To get occasionally unnumbered list items, put the cursor at the very beginning of the item (just after the auto number) and hit Backspace key.

You can’t have holes in the numbering sequence. All you can do is restart from 1.

This will work fine as long as you save .odt. Don’t save .doc(x) because Word has no notion of list styles and you will lose your definition after a round trip.

##Answer to additional need

Any list is multi-level, i.e. it behaves the same as chapter numbering (the underlying device is the same). Therefore, to get “37A” you force your list item to level 2 by typing a Tab at start of its text.

If you later change your mind and want to revert to level 1, put the cursor at the very beginning of the item and press Shift+Tab.

You need to customize the list style to number alphabetically level 2. Right-click on Numbering 123. In Options, select level 2 and set Number to A, B, C and Show sublevels to 2. In Position, ensure properties of level 1 and 2 are the same so that your level 2 is not indented relative to level 1.

Define an auxiliary character style Hidden: in Font Effects, tick Hidden.


You can’t remove the internal dot separator. Your numbering will be “36.A”.


Type a dummy level-1 item in order to set numbering to 36. This item must contain at least one character. Select the item in its entirety and apply Hidden character style. Press Enter.

Reset to Default character style. Press Tab (this sets numbering to 36.A). Type the level-2 item with its eventual index entry. Press Enter (you are at 36.B). Etc.

Type Shift+Tab to continue with 37.

##Comments about the sample file

No offence intended but your styling is even worse than I thought.

Don’t use empty paragraph to vertically space your text. Attributes “Spacing above & below” in Indents & Spacing tab of paragraph style definition is made for this vertical spacing. Of course this requires to carefully design the set styles. From personal experience on this type of document, you need ~15 paragraph styles, not counting Heading n and Contents n. Remember that all built-in styles can be customised and they are already organised hierarchically.

Don’t use direct formatting inside paragraphs. Character styles bring you more versatility and control. Again from personal experience, you need ~10 styles. Start by customising built-ins, notably Emphasis and Strong Emphasis.

In your document you made a big mistake which precludes you from achieved your goal with your lists.

NEVER, NEVER, NEVER, NEVER, NEVER, NEVER, NEVER (yes, repeated seven times) mix lists and chapter numbering. You are creating conflicts. Chapter numbering is a special list. You added manually the list attribute with the toolbar button to Sommario regesto while you also assigned it to level 3 in Tools>Chapter Numbering. This confuses Writer (and you even more) because a paragraph can be attached to only one list counter. Which one is chosen in this error case is unknown and leads to undefined results.

To add to the confusionn the default Format>Bullets a Numbering can be reset in various contexts, restarting numbering without you requesting it!

I first cleaned your document:

  • remove the manual list attribute from the Sommario regesto paragraphs
  • revert level 3 Tools>Chapter Numbering to standard Heading 3
  • clear direct formatting in your Riferimento atto and Sommario regesto paragraphs (just in case)

I modified your Sommario regesto:

  • Outline & Numbering to attach it to list style Numbering 123; I also made sure Outline level is Text Body
  • I erased indents Before text and First line in Indents & Spacing because these parameters are managed by the list style (even in the default case).

Numbering 123 was customized as follows:

  • Position: level 1 and 2 received the same Tab stop at 1.5cm and Indent at 1.5cm (as was set in your initial Sommario regesto
  • Customize: Number 1, 2, 3 and Show sublevels 1 for level 1, A, B, C and 2 for level 2

Unfortunately you bump into a Writer bug. When there is a (left) border with padding, Writer does not compute correctly the indent distance for lines 2+ in a list item.I tried to compensate for this error but all my settings were ignored.

I also created a character style Invisibile with sole attribute Hidden in Font Efects tab.

When this was done, I also restyled your Sommario regesto (2nd level) paragraphs to Sommario regesto because, as I explained, lists in Writer are multi-level.

How to number items 9.Z?

You do not want to “introduce” your 9 series with an explicit sub-title, but this introductory item is necessary to manage numbering.

Therefore I typed a Sommario regesto item containing “Dummy paragraph” before your “4.A Acquisto del signor Salamon”. I selected all the text in this dummy paragraph and applied character style Invisibile. The dummy paragraph will not be printed.

Note that I used "Dummy paragraph as text but a single character is enough.

I put the cursor before “Acquisto” and pressed Tab. This promotes the list item to level 2 and 4.A appears magically.

Special TOC to collect your Sommario regesto paragraphs

You correctly configured by checking Additional styles. I only removed Sommario regesto (2nd level) for the reason above.

But you messed the TOC formatting in the Styles tab. Probably to make this table formatting independent from the real TOC you assigned Default Paragraph Style to all levels. As already mentioned, Default Paragraph Style is a “technical” style which should never be used for text in a document. If your table should have a different appearance than the TOC, create your own styles (one per level, you need two here), starting from built-in Contents n. When they are created, assign them to the levels in the Styles tab.


Noticing that your special TOC needs manual editing to remove the dummy paragraphs, I renamed Sommario regesto (2nd level) to Sommario regesto (invisibile). It is already a child of Sommario regesto but I made sure it is an exact duplicate of it by using the Standard button in every tab. I then checked Hidden in Font Effects.

Now the dummy paragraphs need only to be styled Sommario regesto (invisibile). No need to apply character style Invisibile.

Since Sommario regesto (invisibile) is not selected in Assign Styles for the special TOC, the dummy paragraphs are not collected and no manual step is necessarily to remove them.

The revised sample file is attached here.

To show the community your question has been answered, click the ✓ next to the correct answer, and “upvote” by clicking on the ^ arrow of any helpful answers. These are the mechanisms for communicating the quality of the Q&A on this site. Thanks!

In case you need clarification, edit your question (not an answer which is reserved for solutions) or comment the relevant answer.

Very good, this is what I wanted. I cannot upvote because I don’t have enough points.

You now have enough karma to upvote.

In the meantime, thank you for your reply. However, I don’t get what I need. I’ve added more information to my main post. Thanks!