Contents | Start | End | Previous: KB0397: How do I apply automatic heading numbering but exclude the first few chapters? | Next: KB0399: How do I add a link or cross-reference to an automatically-numbered caption?


KB0398: How do I add captions that automatically use the chapter number and figure number?

See also:
How do I add or remove automatic heading numbering?
Working with numbered headings in the Jutoh manual
Working with fields in the Jutoh manual
Cross-reference dialog in the Jutoh manual
Caption dialog in the Jutoh manual
Sequence editor dialog in the Jutoh manual

To use automatic figure caption numbering preceded with a chapter number (for example, Figure 1.2), you also need to be automatically numbering your chapter headings. The chapter number for the caption will then be extracted from the relevant chapter heading. So to add chapter numbers to the chapter headings and captions, do the following:

  1. In Project Properties/Fields & Numbering (click Edit on the toolbar), check Number headings automatically.

  2. In Project Properties/Fields & Numbering, click Edit Document Outline Style and for the first level in the outline, choose the style you're applying to your chapter headings (e.g. "Heading 1"), and set Numbering style to "1,2,3". Click OK.

  3. In Project Properties/Fields & Numbering, click Edit Sequence Definitions, and click the sequence you want to edit, e.g. "Figure". Set Restart at level to 1, and check Show level. Click OK.

  4. Do (3) again for all the sequences you're using, e.g. "Illustration", "Table".

  5. Click OK and use the menu command Book | Update checking Fields and Numbering. This will update the chapter numbering and fields.

Chapter numbering appearance in each heading can be customised via the outline settings (Project Properties/Fields & Numbering/Edit Document Outline Style), e.g. setting Separator before to "Chapter " and Separator before to ":" to achieve "Chapter 1: Introduction". The chapter number will appear left-aligned in Jutoh, but if your chapter heading is centred, it will be correctly placed in the actual ebook.


Contents | Start | End | Previous: KB0397: How do I apply automatic heading numbering but exclude the first few chapters? | Next: KB0399: How do I add a link or cross-reference to an automatically-numbered caption?