AsciiDoc Markup Syntax Summary

asciidoc --help syntax | sed 's/^  //' | tee MarkupTest.adoc

A summary of the most commonly used markup. For a complete reference see the AsciiDoc User Guide.


Text formatting

bold text (boldface font)
emphasized text (normally italics)
emphasized text
monospaced text (proportional font)
monospaced text (inline literal passthrough)


Document links

(define link target)
caption (link to target id)
caption (link to external HTML file)


URLs

Use normal URL and email addess syntax or:

caption (link to web page)
caption (link to mail recipient)


Images

image:filename     (inline image)
image::filename    (block image)

Document header

The Document Title
==================
author <email>
revision, date

author, email, revision and date are optional.


Section title underlines

Underlined:

Level 0                     (document title)
=======
Level 1
-------
Level 2
~~~~~~~
Level 3
^^^^^^^
Level 4                     (bottom level)
+++++++

Single line:

= Level 0 =                 (document title)
== Level 1 ==
=== Level 2 ===
==== Level 3 ====
===== Level 4 =====         (bottom level)

Level 1

Level 2

Level 3

Level 4

Paragraphs

A normal paragraph. (styles: literal,verse,quote,listing, NOTE,TIP,WARNING,IMPORTANT,CAUTION)

An indented literal
paragraph.

Delimited blocks

Delimiters must begin at left margin.

listing block
listing block

(styles: source,music,graphviz)

literal block
literal block

(styles: listing,verse)

sidebar block sidebar block

quote block quote block

cite
— author

(styles: quote,verse)

example block example block

(styles: NOTE,TIP,WARNING,IMPORTANT,CAUTION)

passthrough block passthrough block

(styles: pass,asciimath,latexmath)

[style]
--
open block
--
(styles: abstract,partintro)

More block elements

[attributes list]
.Block title
// Comment line
include::filename[]

Tables

Table 1. An example table
Column 1 Column 2
6
Three items
1
Item 1
2
Item 2
3
Item 3

Common attributes:

grid:    none,cols,rows,all
frame:   topbot,none,sides,all
options: header,footer
format:  psv,csv,dsv
valign:  top,bottom,middle
width:   1%..100%
cols:    colspec[,colspec,...]
colspec:    [multiplier*][align][width][style]
multiplier: 1...
width:      1... or 1%...100%
align:      [horiz][.vert]
             horiz: < (left), ^ (center), > (right)
             vert:  < (top),  ^ (middle), > (bottom)
style:      d[efault], e[mphasis], m[onospaced], a[sciidoc],
            s[trong], l[iteral], v[erse], h[eader]
cell:       [cellspec]|data
cellspec:   [span*|+][align][style]
span:       [colspan][.rowspan]
             colspan: 1...
             rowspan: 1...

Bulleted lists

  • item text
    • item text
      • item text
        • item text
          • item text
            • item text

(styles: callout,bibliography)


Numbered lists

  1. arabic (decimal) numbering
    1. loweralpha numbering
      1. upperalpha numbering
        1. lowerroman numbering
          1. upperroman numbering
            1. arabic (decimal) numbering
              1. loweralpha numbering
                1. lowerroman numbering
                  1. upperalpha numbering
                    1. upperroman numbering

(styles: arabic,loweralpha,upperalpha,lowerroman,upperroman)


Labeled lists

label
item text

label
item text

label
item text

label
item text

(styles: horizontal,vertical,glossary,qanda,bibliograpy)


More inline elements

[footnote text]
(document footnote)

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s