<?xml version="1.0" encoding="utf-8"?>
<page xmlns="http://projectmallard.org/1.0/" style="xslt-template" id="html.syntax.class">
 <info>
  <link type="guide" xref="html" group="templates"/>
  <link type="guide" xref="templates" group="html"/>
  <desc>Output HTML class values for syntax highlighting.</desc>
  <revision version="3.28" date="2016-01-03" status="final"/>
 </info>
 <title>html.syntax.class</title>
 <synopsis>
  <title>Parameters</title>
  <terms>
   <item>
    <title><code>$node</code></title>
    <p>The source element whose content will be syntax highlighted.</p>
   </item>
  </terms>
 </synopsis>
 <p>This template calls <code xref="html.syntax.class.mode">html.syntax.class.mode</code> on <code>$node</code>. If the result of that
 mode is a suitable language identifier, it outputs appropriate CSS class names
 to enable syntax highlighting. The output should be placed in the <sys>class</sys>
 attribute of a <sys>pre</sys> or similar output element by the calling template.</p>
 <p>Importing stylesheets should implement <code xref="html.syntax.class.mode">html.syntax.class.mode</code> for any source
 elements that may be syntax highlighted, then call this template when building
 the <sys>class</sys> attribute for output elements.</p>
 <list style="compact">
  <title>Calls Modes</title>
  <item>
   <p><link xref="html.syntax.class.mode"/></p>
  </item>
 </list>
</page>
