#
# asciidoc.conf
#
# Asciidoc global configuration file.
# Contains backend independent configuration settings that are applied to all
# AsciiDoc documents.
#

[miscellaneous]
tabsize=8
textwidth=70
newline=\r\n

[glossary]
empty=
amp=&
lt=<
gt=>
brvbar=|

[titles]
underlines="==","--","~~","^^","++"
subs=specialcharacters,quotes,replacements,macros,glossary
# The title cannot start or end with characters that could match a table ruler,
# consequently the title must be 2 or more chars.
blocktitle=^\.(?P<title>[^\s\.\-~_].*[^\-~_])$

[specialcharacters]
&=&amp;
<=&lt;
>=&gt;

[quotes]
*=strong
'=emphasis
`=monospaced

[specialwords]
strongwords=^\s*NOTE: ^\s*TODO: ^\s*TIP: ^\s*IMPORTANT: ^\s*WARNING:

[replacements]
\(C\)=&copy;
\(TM\)=&trade;

# Paragraphs.
[paradef-default]
delimiter=(?P<text>\S.*)
section=paragraph

[paradef-indented]
delimiter=(?P<text>\s+.*)
section=indentedparagraph
presubs=specialcharacters
options=listelement

[macros]
# Inline macros.
# Note backslash prefix required for escape processing.
[\\]?(?P<name>\w(\w|-)*?):(?P<target>\S*?)(\[(?P<caption>.*?)\])=
# Anchor: [[id,xreflabel]]
[\\]?\[\[(?P<caption>[\w"].*?)\]\]=anchor2
# Link: <<id,text>>
[\\]?&lt;&lt;(?P<caption>[\w"].*?)&gt;&gt;=xref2

# Block macros.
^(?P<name>\w(\w|-)*?)::(?P<target>\S*?)(\[(?P<caption>.*?)\])$=#

# Builtin macros.
^(?P<name>\w(\w|-)*?)::(?P<target>\S*?)(\[(?P<caption>.*?)\])$=+

# Delimited blocks.
[blockdef-comment]
delimiter=^/{3,}
options=skip

[blockdef-sidebar]
delimiter=^\*{3,}(\[(?P<args>.*)\])?\**$
section=sidebarblock
options=section,argsline

[blockdef-custom]
delimiter=^\+{3,}(\[(?P<args>.*)\])?\+*$
section=customblock
presubs=macros,glossary

[blockdef-verbatim]
delimiter=^-{3,}(\[(?P<args>.*)\])?-*$
section=verbatimblock
presubs=specialcharacters

[blockdef-indented]
delimiter=^\.{3,}(\[(?P<args>.*)\])?\.*$
section=indentedblock
presubs=specialcharacters

[blockdef-quote]
delimiter=^_{3,}(\[(?P<args>.*)\])?_*$
section=quoteblock
options=section,argsline

# Lists.
[listdef-itemized]
type=simple
delimiter=^\s*- {1,}(?P<text>.+)$
listtag=ilist
itemtag=ilistitem
texttag=ilisttext

[listdef-ordered]
type=simple
delimiter=^\s*\d*\. {1,}(?P<text>.+)$
listtag=olist
itemtag=olistitem
texttag=olisttext

[listdef-variable]
type=variable
delimiter=^\s*(?P<text>[\S].*)::$
listtag=vlist
itemtag=vlistitem
texttag=vlisttext
entrytag=vlistentry
termtag=vlistterm

[listdef-qanda]
# Question and Answer list.
type=variable
delimiter=^\s*(?P<text>[\S].*)\?\?$
listtag=qlist
itemtag=qlistitem
texttag=qlisttext
entrytag=qlistentry
termtag=qlistterm

# Bibliography list.
[listdef-bibliography]
type=simple
delimiter=^\+ {1,}(?P<text>.+)$
listtag=blist
itemtag=blistitem
texttag=blisttext

# Glossary list.
[listdef-glossary]
type=variable
delimiter=^(?P<text>[\S].*):-$
listtag=glist
itemtag=glistitem
texttag=glisttext
entrytag=glistentry
termtag=glistterm

# Alternative list syntaxes.
[listdef-itemized2]
type=simple
delimiter=^\s*\* {1,}(?P<text>.+)$
listtag=ilist
itemtag=ilistitem
texttag=ilisttext

[listdef-ordered2]
type=simple
delimiter=^\s*[.a-z]\. {1,}(?P<text>.+)$
listtag=olist2
itemtag=olistitem
texttag=olisttext

# Tables.
[tabledef-default]
fillchar=-
format=fixed

[tabledef-csv]
fillchar=~
format=csv

[tabledef-dsv]
fillchar=_
format=dsv
