Chapter number and page number at RHS in TOC

Windows 10
LibreOffice 7.4.0.3 (x86) 32 bit

I have an outline document ready for text to be flowed in. It’s mirrored left-right with Chapter Name in the Header and Chapter Number + Page Number in the Footer.

The first few pages use a First Page style; the rest a Default Page Style. Heading 1 is assigned to chapter numbering.

The chapters will be serialised and it makes sense for each to be issued with page numbers starting at 1.

Everything is pretty much in place apart from the TOC.

I have chapter numbers against Heading 1 (Level 1) at the LHS. I’d like to preface the page numbers with for all levels 1-3. I’ve allowed the TOC to be edited to show how:

The downside is that it circumvents the automated features of the TOC and the edits are lost with each update.

I’ve looked at the Entries tab (right-click TOC and choose Edit Index). The structure is predefined and there does not seem a way to edit it:

Is there a way of adding <E#> immediately before the <#> (page number) element?

If not, does anyone know of a work-around?

Thanks,
Ric
NB: Only 1 image allowed as a new user. Apologies

I have a similar issue. Can someone please attach a sample document after applying the steps in the accepted answer?

@shantanuo: is your issue really the same? Please describe your specification/requirement as if you were ordering the job to be done by some professional. The best thing to do could be to open your own question, linking it to the present one. As always, mention OS name, LO version and save format.

I tried the instructions but could not add a dash in E# and #. I wish there was a graphical/ video tutorial for this (for beginners). And I could not find any suitable template in File - New - Template. I found an extension called “SIL Templates for master thesis”. But that does not show numbering exactly like this.

@shantanuo: better ask your question with full details. Describe your specification as accurately as possible. And, of course, don’t forget OS name, LO version and save format.

The Structure and Formatting line in Entries for the TOC configuration is not “frozen”; you can customise it at will

To add a new descriptor, click in the text entry box preceding another decscriptor, then click on the relevant button.

In your case, the initial configuration is LSE#ET#LE.

  • click in the white box preceding #
  • press Chapter No.
  • enter a dash in the box between E# and #

Your structure line should now read:
LSE#ETE#-#LE

EDIT
To keep only the level-1 chapter number for E#, click on the descriptor. Several settings are now displayed in the dialog. Set Evaluate up to level: to 1 to show only level 1.

1 Like

Hi ajlittoz,

Thanks for your reply. I tried lots of things but never thought of clicking in the spaces between. Excellent solution. Applying the edits to levels 1, 2 and 3, works, but chapter numbers display only for Level 1. I’m getting this:

zTCQ0sjL6SX3mRdu.png

I checked the paragraph style for H2, H3, etc [format → paragraph → outline & list] and it looks OK:

Outline: Level 2, Apply List Style: Chapter Numbering

Both of the above are greyed-out.

I’m obviously missing something but can’t think what it is. Any idea what I’ve overlooked?

Thanks,

Ric

The stance is to be done for every level.


But I notice that your levels 2 and 3 are unnumbered. Consequently descriptor E# returns “void”.


To fix this, in Tools>Chapter Numbering, enable numbering in levels 2 and 3. If you don’t want these levels to appear with number in the narrative, assign a character style to the number (in Tools>Chapter Numbering) with attribute Hidden.


To eliminate the number in the TOC before the heading, delete E# in the structure line.

Note you may have to configure carefully your numbering to get the desired result in the TOC.

I tried lots of things but the leading chapter number defeated me. Then, some geological age later, it dawned that I could try deleting the leading <E#> entry in the Edit Index → Entries → Structure & Format dialogue.
The result is exactly as I’d hoped:
image
Thank you so much for your well structured reply. Much appreciated.
Ric

1 Like

Hi,
I follow your steps by removing the <E#>, but the page number of my TOC just shows as your first picture.

At the same time, I hope the leading chapter number shouldn’t be removed, Can anyone help to solve this issue?

Thanks!

@chang-space Without any information besides “I have a problem”, no one can help you. Since your case may be different, open your own question (mentioning the fact you read this question – with a link to it). Give maximum technical and factual details: OS name, LO version, save format; what you really did to create your TOC, its structure line(s); …

For best advice attach a sample file showing the issue.

2 Likes