Element Domain Specialization Step 5: Extend DITA Open Toolkit XHTML Processor

Per the documentation of the types in the XML domain, we need to create XSLT templates for each of the different mentions to produce the appropriate output effects.

Because the XML domain only defines specializations of <keyword>, the XSLT required is quite simple and requires very little knowledge of XSLT itself.

The Open Toolkit is designed to allow extension of base functionality through "plugins." This allows you to create processing specific to your specialization and then easily deploy it without directly modifying the base Toolkit processes. All Toolkit transformation types should provide appropriate extension points for plugins, but not all do. However, both the HTML and PDF transformation types do provide the extension points you need to easily add processing for new specializations.

The basic process is as follows:
  1. Create an empty starting XSLT stylesheet in a directory you control (that is, outside the scope of the DITA Open Toolkit) and add an import of the base Toolkit-supplied HTML transform.
  2. Create type-specific match templates for the element types in the XML domain.
  3. Package the transform as an Open Toolkit plugin.
  4. Deploy the plugin and test it.