Add Captions to Images, Figures, and Tables
You can use the Scroll Title macro to add captions to images, figures, and tables in exports.
To use the macro, insert it into a page, highlight it and then select Edit. You can then enter the caption you want to assign to the content and after confirming, move that content into the macro.
You can also further style how the captions are exported – this formatting is done when customizing an export template.
Please note that only one block element (ie. an image or a table) should be nested within the Scroll Title macro. Including multiple objects within a single Scroll Title macro is not supported and can cause incorrect export behaviour.
Linking to captions
By editing an inserted Scroll Title macro you can also associate an anchor element which can be linked to. Any links to the anchor element for the caption will be preserved in the export.
To do this, simply select Edit after inserting the macro to a page and then define the text for the anchor in the Anchor Name field. Following this, you can then add a link to the same Confluence page and/or a page in the same space which directs to the anchor for the caption. For more information about adding Anchors in Confluence please see their related documentation.
Adjust caption position and alignment
After adding the desired caption to your figure you can also customize the placement and alignment of the caption.
With the macro parameter title-position, you can decide whether you want the caption to appear above or below the table or figure. Additionally, the title-alignment macro parameter allows you to define the alignment of the caption text. You can choose between the alignments: Left, Center, Right and Justify. The Justify alignment differs from the other directional alignments and allows you to write longer captions, on several lines, in a good looking way. The letter- and word-spacing gets aligned so that the caption text stays within a predefined squared structure.
Interested in adding a Table of Tables/Figures?
Through the use of placeholders in the customizable template you can add a Table of Tables and/or Table of Figures to your PDF Export. This feature enables users to automatically generate a list of tables and figures from the exported Confluence pages. You can read more about this process in our Customize Document Sections documentation.
Adjust caption position and alignment
After adding the desired caption to your figure you can also customize the placement and alignment of the caption.
With the macro parameter title-position, you can decide whether you want the caption to appear above or below the table or figure. Additionally, the title-alignment macro parameter allows you to define the alignment of the caption text. You can choose between the alignments: Left, Center, Right and Justify.
The Justify alignment differs from the other directional alignments and allows you to write longer captions, on several lines, in a good looking way. The letter- and word-spacing gets aligned so that the caption text stays within a predefined squared structure.
Please note that the caption alignment is always taken from the template. Therefore, make sure that the table- and figure captions in the template always correspond with your settings in the Scroll Title macro.