<code>

Code, inline

Inline code snippets, including markup fragments

Remarks

This element’s content is typically is displayed or printed in a monofont.

Attributes

xml:id XML Unique Identifier
xreflabel Cross-Reference Label

Related Elements

Computer code to be interspersed with text should be tagged with the <code> element. The <programlisting> element should be used for block displays of code, for example, entire programs, in which whitespace (such as tabs, line feeds, and spaces) should be preserved.

Model Description

Any combination of:

This element may be contained in:

<emphasis>, <link>, <para>, <quote>, <subtitle>, <td>, <term>, <th>, <title>

Example

         
...
<para>Information processing, especially text markup, was primitive in the colony.
For example, most text stores were in XML! Documents may have looked like this:
<programlisting>
   &lt;teiHeader&gt;
      &lt;fileDesc&gt;
         &lt;titleStmt&gt;
            &lt;title&gt;Farming in the New World&lt;/title&gt;
      ...
        &lt;/titleStmt&gt;
      &lt;/fileDesc&gt;
  &lt;/teiHeader&gt;
</programlisting>
Notice the paired Tags: <code>&lt;title&gt;</code> and <code>&lt;/title&gt;</code>
and the primitive use of indenting. Unusual features of the colonists data
processing practices included:
<variablelist>
<varlistentry>
<term>Tags</term>
<listitem><para>Meaningful descriptions of the information enclosed by the
markers</para></listitem>
</varlistentry>
<varlistentry>
<term>Balance</term>
<listitem><para>All markup is both opened and closed (or explicitely
empty)</para></listitem>
</varlistentry>
</variablelist>
</para>
...


         

Module

balisage-1-1