Skip to main content
Participant
January 30, 2024
Answered

Table of content: excerpt text

  • January 30, 2024
  • 2 replies
  • 1113 views

Hello everyone,

I'm handling a document where I need to manage a Table of figures. Since it's quite a technical document, the captions are sometimes a bit long. I'd like to include in the ToF only a part of them. For example: "Figure 1: General envelope. The blablablalbla": I'd like to have only "Figure 1: General envelope" in the ToF. 

 

My first idea was to use two paragraph styles (let's say Figures and FiguresNOTOF) and use the former in the ToF, but I can't help having a line break in the caption, which should be avoided. 

 

I browsed some discussions here but I couldn't find the best way to achieve this.

What's the best strategy here?

 

Thank you!

 

 

This topic has been closed for replies.
Correct answer Peter Kahrel

Your idea of using two paragraph styles is correct. But instead of adding the abbreviated caption to the 'real' caption, add it in a sperate text frame and anchor it in the caption. You can move the anchored frame largely away from the page, only a fraction of the frame needs to be on the page. Then in the ToF use the paragraph style applied to the abbreviated caption.

2 replies

Peter Kahrel
Community Expert
Community Expert
January 30, 2024

I assumed that abbreviating a caption wouldn't always be as simple as chopping it off somewhere.

Peter Kahrel
Community Expert
Peter KahrelCommunity ExpertCorrect answer
Community Expert
January 30, 2024

Your idea of using two paragraph styles is correct. But instead of adding the abbreviated caption to the 'real' caption, add it in a sperate text frame and anchor it in the caption. You can move the anchored frame largely away from the page, only a fraction of the frame needs to be on the page. Then in the ToF use the paragraph style applied to the abbreviated caption.

FRIdNGE
January 30, 2024

Hi Peter,

 

Why not just insert a Grep style in the "Caption" TOC para style that makes invisible all the text after the first dot [automatic] or after a non-joiner [manually placed by the op]?

 

Char Style: Invisible

Grep Expression: [.~j].+$

 

(^/)  The Jedi

Stefsue
Participating Frequently
October 25, 2024

I have the same issue example:

Doctrinal Fidelity (79th A., 2024) .............12

I don't want the text in parenthesis to show in the TOC and there is no way I can go back into my document and created new text boxes for all of them. It is a HUGE document.

 

I tried your grep expression but I am not doing it right. What are the parameters for the Char Style?

Also, the parenthesis has a small type char style applied to it. Unlike the bold regular text of the title.

 

HELP!