#
# docbook.conf
#
# Asciidoc configuration file.
# Default docbook backend.
#

[miscellaneous]
outfilesuffix=.xml
# Printable page width in pts.
pagewidth=425
pageunits=pt

[attributes]
basebackend=docbook
basebackend-docbook=

[replacements2]
# Line break markup. Custom processing instruction in fo.xsl.
(?m)^(.*)\s\+$=\1<?asciidoc-br?>

[replacements]
ifdef::asciidoc7compatible[]
# Superscripts.
\^(.+?)\^=<superscript>\1</superscript>
# Subscripts.
~(.+?)~=<subscript>\1</subscript>
endif::asciidoc7compatible[]

[ruler-blockmacro]
# Uses a custom processing instruction in fo.xsl.
<?asciidoc-hr?>

[pagebreak-blockmacro]
# Uses a custom processing instruction in fo.xsl.
<?asciidoc-pagebreak?>

[blockdef-pass]
latexmath-style=template="latexmathblock",subs=[]

[macros]
# math macros.
(?su)[\\]?(?P<name>latexmath):(?P<subslist>\S*?)\[(?P<passtext>.*?)(?<!\\)\]=[]
(?u)^(?P<name>latexmath)::(?P<subslist>\S*?)(\[(?P<passtext>.*?)\])$=#[]

[latexmath-inlinemacro]
<inlineequation>
<alt><![CDATA[{passtext}]]></alt>
<inlinemediaobject><textobject><phrase></phrase></textobject></inlinemediaobject>
</inlineequation>

[latexmath-blockmacro]
<informalequation>
<alt><![CDATA[{passtext}]]></alt>
<mediaobject><textobject><phrase></phrase></textobject></mediaobject>
</informalequation>

[latexmathblock]
<equation{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}><title>{title}</title>
{title%}<informalequation{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<alt><![CDATA[|]]></alt>
<mediaobject><textobject><phrase></phrase></textobject></mediaobject>
{title#}</equation>
{title%}</informalequation>

[image-inlinemacro]
<inlinemediaobject>
  <imageobject>
  <imagedata fileref="{imagesdir=}{imagesdir?/}{target}"{width? contentwidth="{width}"}{height? contentdepth="{height}"}/>
  </imageobject>
  <textobject><phrase>{1={target}}</phrase></textobject>
</inlinemediaobject>

[image-blockmacro]
<figure{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}{pgwide-option? pgwide="1"}><title>{title}</title>
{title%}<informalfigure{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>{pgwide-option?<?dbfo pgwide="1"?>}
<mediaobject>
  <imageobject>
  <imagedata fileref="{imagesdir=}{imagesdir?/}{target}"{width? contentwidth="{width}"}{height? contentdepth="{height}"}{scaledwidth? width="{scaledwidth}" scalefit="1"}{align? align="{align}"}/>
  </imageobject>
  <textobject><phrase>{1={target}}</phrase></textobject>
</mediaobject>
{title#}</figure>
{title%}</informalfigure>

[indexterm-inlinemacro]
# Index term.
# Generate separate index entries for primary, secondary and tertiary
# descriptions.
# Primary only.
{2%}<indexterm>
{2%}  <primary>{1}</primary>
{2%}</indexterm>
# Primary and secondary.
{2#}{3%}<indexterm>
{2#}{3%}  <primary>{1}</primary><secondary>{2}</secondary>
{2#}{3%}</indexterm>
{2#}{3%}<indexterm>
{2#}{3%}  <primary>{2}</primary>
{2#}{3%}</indexterm>
# Primary, secondary and tertiary.
{3#}<indexterm>
  <primary>{1}</primary><secondary>{2}</secondary><tertiary>{3}</tertiary>
{3#}</indexterm>
{3#}<indexterm>
  <primary>{2}</primary><secondary>{3}</secondary>
{3#}</indexterm>
{3#}<indexterm>
  <primary>{3}</primary>
{3#}</indexterm>

[indexterm2-inlinemacro]
# Index term.
# Single entry index term that is visible in the primary text flow.
<indexterm><primary>{1}</primary></indexterm>{1}

[footnote-inlinemacro]
# Footnote.
<footnote><simpara>{0}</simpara></footnote>

[footnoteref-inlinemacro]
# Footnote reference.
{2#}<footnote id="{1}"><simpara>{2}</simpara></footnote>
{2%}<footnoteref linkend="{1}" />

[callout-inlinemacro]
# Callout.
<co id="{coid}"/>

# List tags.
[listtags-bulleted]
list=<itemizedlist{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}{compact-option? spacing="compact"}>{title?<title>{title}</title>}|</itemizedlist>
item=<listitem>|</listitem>
text=<simpara>|</simpara>

[listtags-numbered]
list=<orderedlist{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"} numeration="{style}"{compact-option? spacing="compact"}>{title?<title>{title}</title>}|</orderedlist>
item=<listitem>|</listitem>
text=<simpara>|</simpara>

[listtags-labeled]
list=<variablelist{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>{title?<title>{title}</title>}|</variablelist>
entry=<varlistentry>|</varlistentry>
label=
term=<term>|</term>
item=<listitem>|</listitem>
text=<simpara>|</simpara>

[listtags-horizontal]
# Horizontal labeled list (implemented with two column table).
# Hardwired column widths to 30%,70% because the current crop of PDF
# generators do not auto calculate column widths.
 list=<{title?table}{title!informaltable}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}{style? tabstyle="{style}"}{pgwide-option? pgwide="1"} frame="none" colsep="0" rowsep="0">{title?<title>{title}</title>}<tgroup cols="2"><colspec colwidth="{labelwidth=15}*"/><colspec colwidth="{itemwidth=85}*"/><tbody valign="top">|</tbody></tgroup><{title?/table}{title!/informaltable}>
entry=<row>|</row>
label=<entry>|</entry>
term=<simpara>|</simpara>
item=<entry>|</entry>
text=<simpara>|</simpara>

[listtags-callout]
list=<calloutlist{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>{title?<title>{title}</title>}|</calloutlist>
item=<callout arearefs="{coids}">|</callout>
text=<simpara>|</simpara>

[listtags-qanda]
list=<qandaset{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>{title?<title>{title}</title>}|</qandaset>
entry=<qandaentry>|</qandaentry>
label=<question>|</question>
term=<simpara>|</simpara>
item=<answer>|</answer>
text=<simpara>|</simpara>

[listtags-bibliography]
list=
item=<bibliomixed>|</bibliomixed>
text=<bibliomisc>|</bibliomisc>

[listtags-glossary]
list=
entry=<glossentry>|</glossentry>
label=
term=<glossterm>|</glossterm>
item=<glossdef>|</glossdef>
text=<simpara>|</simpara>

[tags]
# Quoted text
emphasis=<emphasis>|</emphasis>
strong=<emphasis role="strong">|</emphasis>
monospaced=<literal>|</literal>
singlequoted={amp}#8216;|{amp}#8217;
doublequoted={amp}#8220;|{amp}#8221;
unquoted=
subscript=<subscript>|</subscript>
superscript=<superscript>|</superscript>

# Inline macros
[http-inlinemacro]
<ulink url="{name}:{target}">{0={name}:{target}}</ulink>
[https-inlinemacro]
<ulink url="{name}:{target}">{0={name}:{target}}</ulink>
[ftp-inlinemacro]
<ulink url="{name}:{target}">{0={name}:{target}}</ulink>
[file-inlinemacro]
<ulink url="{name}:{target}">{0={name}:{target}}</ulink>
[irc-inlinemacro]
<ulink url="{name}:{target}">{0={name}:{target}}</ulink>
[mailto-inlinemacro]
<ulink url="mailto:{target}">{0={target}}</ulink>
[callto-inlinemacro]
<ulink url="{name}:{target}">{0={target}}</ulink>
[link-inlinemacro]
<ulink url="{target}">{0={target}}</ulink>
# anchor:id[text]
[anchor-inlinemacro]
<anchor id="{target}" xreflabel="{0=[{target}]}"/>
# [[id,text]]
[anchor2-inlinemacro]
<anchor id="{1}" xreflabel="{2=[{1}]}"/>
# [[[id]]]
[anchor3-inlinemacro]
<anchor id="{1}" xreflabel="[{1}]"/>[{1}]
# xref:id[text]
[xref-inlinemacro]
<link linkend="{target}">{0}</link>
{2%}<xref linkend="{target}"/>
# <<id,text>>
[xref2-inlinemacro]
<link linkend="{1}">{2}</link>
{2%}<xref linkend="{1}"/>
# // comment line
[comment-inlinemacro]
{showcomments#}<remark>{passtext}</remark>

[comment-blockmacro]
template::[comment-inlinemacro]

[literal-inlinemacro]
# Inline literal.
<literal>{passtext}</literal>

# Special word macros
[emphasizedwords]
<emphasis>{words}</emphasis>
[monospacedwords]
<literal>{words}</literal>
[strongwords]
<emphasis role="strong">{words}</emphasis>

# Paragraph substitution.
[paragraph]
<formalpara{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}><title>{title}</title><para>
{title%}<simpara{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
{title%}</simpara>
{title#}</para></formalpara>
{empty}

[admonitionparagraph]
<{name}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}><simpara>|</simpara></{name}>

[literalparagraph]
# The literal block employs the same markup.
template::[literalblock]

[verseparagraph]
template::[verseblock]

# Delimited blocks.
[literalblock]
<example{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}><title>{title}</title>
{title#}<literallayout class="monospaced">
{title%}<literallayout{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"} class="monospaced">
|
</literallayout>
{title#}</example>

[listingblock]
<example{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}><title>{title}</title>
{title#}<screen>
{title%}<screen{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
</screen>
{title#}</example>

[sidebarblock]
<sidebar{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</sidebar>

[abstractblock]
<abstract{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</abstract>

[quoteblock]
<blockquote{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
# Include attribution only if either {attribution} or {citetitle} is defined.
{attribution#}<attribution>
{attribution%}{citetitle#}<attribution>
{attribution}
<citetitle>{citetitle}</citetitle>
{attribution#}</attribution>
{attribution%}{citetitle#}</attribution>
|
</blockquote>

[verseblock]
<blockquote{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
# Include attribution only if either {attribution} or {citetitle} is defined.
{attribution#}<attribution>
{attribution%}{citetitle#}<attribution>
{attribution}
<citetitle>{citetitle}</citetitle>
{attribution#}</attribution>
{attribution%}{citetitle#}</attribution>
<literallayout>
|
</literallayout>
</blockquote>

[exampleblock]
<{title?example}{title!informalexample}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</{title?example}{title!informalexample}>

[admonitionblock]
<{name}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</{name}>

# Tables.
[tabletags-default]
colspec=<colspec colname="col_{colnumber}" colwidth="{width!{colpcwidth}*}{width?{colabswidth}{pageunits}}"/>
bodyrow=<row>|</row>
headdata=<entry align="{align}" valign="{valign}"{colspan@1:: namest="col_{colstart}" nameend="col_{colend}"}{morerows@0:: morerows="{morerows}"}>|</entry>
bodydata=<entry align="{align}" valign="{valign}"{colspan@1:: namest="col_{colstart}" nameend="col_{colend}"}{morerows@0:: morerows="{morerows}"}>|</entry>
paragraph=<simpara>|</simpara>

[tabletags-emphasis]
paragraph=<simpara><emphasis>|</emphasis></simpara>

[tabletags-strong]
paragraph=<simpara><emphasis role="strong">|</emphasis></simpara>

[tabletags-monospaced]
paragraph=<simpara><literal>|</literal></simpara>

[tabletags-verse]
bodydata=<entry align="{align}" valign="{valign}"{colspan@1:: namest="col_{colstart}" nameend="col_{colend}"}{morerows@0:: morerows="{morerows}"}><literallayout>|</literallayout></entry>
paragraph=

[tabletags-literal]
bodydata=<entry align="{align}" valign="{valign}"{colspan@1:: namest="col_{colstart}" nameend="col_{colend}"}{morerows@0:: morerows="{morerows}"}><literallayout class="monospaced">|</literallayout></entry>
paragraph=

[tabletags-asciidoc]
paragraph=

[table]
<{title?table}{title!informaltable}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}{pgwide-option? pgwide="1"}
frame="{frame=all}"
{grid%rowsep="1" colsep="1"}
rowsep="{grid@none|cols:0:1}" colsep="{grid@none|rows:0:1}"
>
<title>{title}</title>
<?dbfo keep-together="{breakable-option#auto}"?>
<?dbfo keep-together="{unbreakable-option#always}"?>
<tgroup cols="{colcount}">
{colspecs}
{headrows#}<thead>
{headrows}
{headrows#}</thead>
{footrows#}<tfoot>
{footrows}
{footrows#}</tfoot>
<tbody>
{bodyrows}
</tbody>
</tgroup>
</{title?table}{title!informaltable}>

#--------------------------------------------------------------------
# Deprecated old table definitions.
#

[old_tabledef-default]
template=old_table
colspec=<colspec colwidth="{colwidth}{pageunits}" align="{colalign}"/>
bodyrow=<row>|</row>
bodydata=<entry>|</entry>

[old_table]
<{title?table}{title!informaltable}{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"} pgwide="0"
frame="{frame=topbot}"
{grid%rowsep="0" colsep="0"}
rowsep="{grid@none|cols:0:1}" colsep="{grid@none|rows:0:1}"
>
<title>{title}</title>
<tgroup cols="{cols}">
{colspecs}
{headrows#}<thead>
{headrows}
{headrows#}</thead>
{footrows#}<tfoot>
{footrows}
{footrows#}</tfoot>
<tbody>
{bodyrows}
</tbody>
</tgroup>
</{title?table}{title!informaltable}>

# End of deprecated old table definitions.
#--------------------------------------------------------------------

# Special sections.
[preface]
<preface{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</preface>

[index]
<index{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</index>

[bibliography]
<bibliography{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</bibliography>

[glossary]
<glossary{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</glossary>

[appendix]
<appendix{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</appendix>

[floatingtitle]
<bridgehead{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"} renderas="sect{level}">{title}</bridgehead>


[header-declarations]
<?xml version="1.0" encoding="{encoding}"?>
<!DOCTYPE {doctype-article?article}{doctype-book?book}{doctype-manpage?refentry} PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">

[docinfo]
    <title>{doctitle}</title>
    <date>{revdate}</date>
# To ensure valid articleinfo/bookinfo when there is no AsciiDoc header.
    {doctitle%}{revdate%}<date>{docdate}</date>
    {authored#}<author>
        <firstname>{firstname}</firstname>
        <othername>{middlename}</othername>
        <surname>{lastname}</surname>
        <affiliation><orgname>{orgname}</orgname></affiliation>
        <email>{email}</email>
    {authored#}</author>
    <authorinitials>{authorinitials}</authorinitials>
<revhistory><revision>{revnumber?<revnumber>{revnumber}</revnumber>}<date>{revdate}</date>{authorinitials?<authorinitials>{authorinitials}</authorinitials>}{revremark?<revremark>{revremark}</revremark>}</revision></revhistory>
# Include file named like source document with -docinfo.xml suffix
# if it exists and if the docinfo attribute is defined.
# include it as the document history.
{docinfo#}{include:{docdir}/{docname}-docinfo.xml}
# DEPRECTED: Use docinfo.
{revisionhistory#}{include:{docdir}/{docname}-revhistory.xml}
# DEPRECTED: Use corpname in preference to companyname.
    <corpname>{companyname}</corpname>
    <corpname>{corpname}</corpname>

#-------------------------
# article document type
#-------------------------
ifdef::doctype-article[]

[header]
template::[header-declarations]

<article lang="{lang}">
<articleinfo>
template::[docinfo]
</articleinfo>

[footer]
</article>

[preamble]
# Untitled elements between header and first section title.
|

[abstract]
<abstract{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
</abstract>

[sect1]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

[sect2]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

[sect3]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

[sect4]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

endif::doctype-article[]

#-------------------------
# manpage document type
#-------------------------
ifdef::doctype-manpage[]

[replacements]
# The roff format does not substitute special characters so just print them as
# text.
\(C\)=(C)
\(TM\)=(TM)

[header]
template::[header-declarations]
<refentry lang="{lang}">
<refmeta>
<refentrytitle>{mantitle}</refentrytitle>
<manvolnum>{manvolnum}</manvolnum>
<refmiscinfo class="source">{mansource}</refmiscinfo>
<refmiscinfo class="version">{manversion}</refmiscinfo>
<refmiscinfo class="manual">{manmanual}</refmiscinfo>
</refmeta>
<refnamediv>
    <refname>{manname1}</refname>
    <refname>{manname2}</refname>
    <refname>{manname3}</refname>
    <refname>{manname4}</refname>
    <refname>{manname5}</refname>
    <refname>{manname6}</refname>
    <refname>{manname7}</refname>
    <refname>{manname8}</refname>
    <refname>{manname9}</refname>
    <refpurpose>{manpurpose}</refpurpose>
</refnamediv>

[footer]
</refentry>

# Section macros
[synopsis]
<refsynopsisdiv{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
</refsynopsisdiv>

[sect1]
<refsect1{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</refsect1>

[sect2]
<refsect2{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</refsect2>

[sect3]
<refsect3{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</refsect3>

endif::doctype-manpage[]

#-------------------------
# book document type
#-------------------------
ifdef::doctype-book[]

[header]
template::[header-declarations]

<book lang="{lang}">
<bookinfo>
template::[docinfo]
</bookinfo>

[footer]
</book>

[preamble]
# Preamble is not allowed in DocBook book so wrap it in a preface.
<preface{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title></title>
|
</preface>

[dedication]
<dedication{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
</dedication>

[colophon]
<colophon{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
|
</colophon>

[sect0]
<part{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</part>

[sect1]
<chapter{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</chapter>

[sect2]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

[sect3]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

[sect4]
<section{id? id="{id}"}{role? role="{role}"}{reftext? xreflabel="{reftext}"}>
<title>{title}</title>
|
</section>

endif::doctype-book[]

ifdef::sgml[]
#
# Optional DocBook SGML.
#
# Most of the differences between DocBook XML and DocBook SGML boils
# down to the empty element syntax: SGML does not like the XML empty
# element <.../> syntax, use <...> instead.
#
[miscellaneous]
outfilesuffix=.sgml

[header-declarations]
<!DOCTYPE {doctype-article?article}{doctype-book?book}{doctype-manpage?refentry} PUBLIC "-//OASIS//DTD DocBook V4.1//EN">

[tabledef-default]
colspec=<colspec colwidth="{colabswidth}{pageunits}" align="{colalign}">

[image-inlinemacro]
<inlinemediaobject>
  <imageobject>
  <imagedata fileref="{imagesdir=}{imagesdir?/}{target}"{width? width="{width}"}{height? depth="{height}"}>
  </imageobject>
  <textobject><phrase>{1={target}}</phrase></textobject>
</inlinemediaobject>

[image-blockmacro]
<figure><title>{title}</title>
{title%}<informalfigure>
<mediaobject>
  <imageobject>
  <imagedata fileref="{imagesdir=}{imagesdir?/}{target}"{width? width="{width}"}{height? depth="{height}"}>
  </imageobject>
  <textobject><phrase>{1={target}}</phrase></textobject>
</mediaobject>
{title#}</figure>
{title%}</informalfigure>

# Inline macros
[xref-inlinemacro]
<link linkend="{target}">{0}</link>
{2%}<xref linkend="{target}">
[xref2-inlinemacro]
# <<id,text>>
<link linkend="{1}">{2}</link>
{2%}<xref linkend="{1}">
[anchor-inlinemacro]
<anchor id="{target}" xreflabel="{0=[{target}]}">
[anchor2-inlinemacro]
# [[id,text]]
<anchor id="{1}" xreflabel="{2=[{1}]}">

endif::sgml[]
