<?xml version="1.0"?>
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
<concept id="concept_51FA079CBA0E4FC0B6AB31FB9B4031A0">
<title>Examples</title>
<shortdesc>This is a brief description of what can be expected in the DITA output.</shortdesc>
<conbody>
<note>Other output formats will greatly differ from the DITA output as not all tags have been implemented in the C++ DITA specialisation so far. See the <xref href="supported_commands.dita#supported.doxygen.cmds">Supported Doxygen Commands</xref> document for a list of commands supported in the DITA output. It is recommended that only supported commands are used when writing in source comments destined to go into DITA output.</note>
<section id="section_C6B7FEE210CC4CA9A08339AB9F1E4139">
<title>code and endcode</title><p>Use \code and \endcode to enclose code examples.</p>
<table id="table_C7DDB6EC2E33422E8167F7A56AD6F32C">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>\code
if ( firstEnabled == -1 )
firstEnabled = ii ;http://lohdr001.europe.nokia.com/
if ( aPlugInArray[ii]->DisplayName().FindF( aPreferredSupplier ) == KErrNotFound )
aPlugInArray[ii]->SetDisabled( ETrue ) ;
else
matchCount++ ;
\endcode</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><codeblock>if ( firstEnabled == -1 )
firstEnabled = ii ;http://lohdr001.europe.nokia.com/
if ( aPlugInArray[ii]->DisplayName().FindF( aPreferredSupplier ) == KErrNotFound )
aPlugInArray[ii]->SetDisabled( ETrue ) ;
else
matchCount++ ;</codeblock></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section id="section_9E8CA950A1D94145859BA8200C31A4E6">
<title>leave</title><p>A \leave tag is transformed into two seperate paragraphs, one that contains the text "leave" and another that contains the content after the \leave tag.</p>
<table id="table_CA3D59ADE1014F899B24C3B849E6E06F">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>\leave KErrNoMemory - insufficient free memory for object creation when decoding parts</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><p><b>leave</b></p>
<p>KErrNoMemory - insufficient free memory for object creation when decoding parts </p></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section id="section_59E7D620D54945738342468802C56283">
<title>li</title><p>\li tag items are transformed into DITA <li> elements within an unordered list <ul>. The \li tags are non nestable.</p>
<table id="table_505201D3EE2B4DF6B8C45735AD2D1951">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>\li apples
\li bananas
\li bacon</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><ul>
<li>
<p>apples </p>
</li>
<li>
<p>bananas </p>
</li>
<li>
<p>bacon</p>
</li>
</ul></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section id="section_912A579B10924E2A9FB8741385355757">
<title>note</title><p>\note is transformed into a DITA <note> element with the type attribute equaling "note". </p>
<table id="table_524248643B824DF9AA531F3955825938">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>\note It's raining, use an umbrella.</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><note type="note">
<p>It's raining, use an umbrella. </p>
</note></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section id="section_9991905C4CB74F4D8096EF6639395EB7">
<title>par</title><p>The \par tag can take a title, the line afterwards is the actual parapraph. The title is optional and can be omited by leaving the first line blank and entering the paragraph on the line below the \par tag.</p>
<table id="table_30246167D3864A46ADA8B8DF091ED470">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>/**
\par Paragraph Title
Paragraph contents.
*/</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><p>
<b>Paragraph Title</b>
</p>
<p>Paragraph contents.</p></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section id="section_CAF6401753504DAFB6733618312F939C">
<title>verbatim and endverbatim</title><p>Text within \verbatim and \endverbatim tags will be reproduced in DITA exactly as it appeared in the source.</p>
<table id="table_CFB1352F412147CA819691B75C556B95">
<tgroup cols="2">
<colspec colnum="1" colname="col1" colwidth="1.00*"/>
<colspec colnum="2" colname="col2" colwidth="8.10*"/>
<tbody>
<row>
<entry colname="col1">In Source</entry>
<entry colname="col2">
<codeblock>\verbatim
typedef struct
{
double x;
double y;
double z;
char * name;
int namelength;
} point3d;
\endverbatim</codeblock>
</entry>
</row>
<row>
<entry colname="col1">DITA Output</entry>
<entry colname="col2">
<codeblock><p><pre>
typedef struct
{
double x;
double y;
double z;
char * name;
int namelength;
} point3d;
</pre></p></codeblock>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
</conbody>
</concept>