cogTag content as an illustration and with an optional caption
Recommended
TypeJAR
CategoryMacro
Developed by

XWiki Development Team

Active Installs132
Rating
Rate!
0 Votes
LicenseGNU Lesser General Public License 2.1
Compatibility

XWiki 10.2+

Installable with the Extension Manager

Description

Equivalent of the HTML5 <figure> element. Allows to tag content as containing an illustration, with an optional caption.

Usage

Without caption:

{{figure}}
... any content here...
{{/figure}}

With caption before the illustration:

{{figure}}
{{figureCaption}}...caption content here{{/figureCaption}}

... any content here...
{{/figure}}

With caption after the illustration:

{{figure}}
... any content here...

{{figureCaption}}...caption content here{{/figureCaption}}
{{/figure}}

Examples

Image figure

{{figure}}
[[image:macaque.jpg||alt="Macaque in the trees"]]

{{figureCaption}}A cheeky macaque, Lower Kintaganban River, Borneo. Original by [[Richard Clark>>http://www.flickr.com/photos/rclark/]]{{/figureCaption}}
{{/figure}}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque tincidunt at nunc lobortis vulputate. Phasellus tempus, urna eget commodo lacinia, sapien orci elementum nibh, ac condimentum metus quam vel mauris. Aliquam vehicula vehicula fermentum. In sodales augue eu ex accumsan tincidunt. Sed pellentesque nunc sit amet accumsan posuere. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Pellentesque congue rhoncus tortor vel tincidunt. Nunc tortor nisi, efficitur non nunc vitae, semper tincidunt libero. Suspendisse diam augue, euismod quis molestie nec, consequat sollicitudin mi. Phasellus sit amet sapien ante. Suspendisse ac nulla in orci efficitur porttitor sed nec mi.

Generates:

image-example-default.png

And if you apply some custom CSS you can get:

image-example.png

Table figure

{{figure}}
|= Headcell1 |= Headcell2
| cell1 | cell2

{{figureCaption}}Table caption{{/figureCaption}}
{{/figure}}        

Related

Prerequisites & Installation Instructions

We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.

You can also use the manual method which involves dropping the JAR file and all its dependencies into the WEB-INF/lib folder and restarting XWiki.

Dependencies

Dependencies for this extension (org.xwiki.rendering:xwiki-rendering-macro-figure 11.6.1):

Tags:
Created by Vincent Massol on 2018/03/11 20:13
    

Get Connected