DITA-features-in-docs.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. <!DOCTYPE html
  2. SYSTEM "about:legacy-compat">
  3. <html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="UTF-8"><meta name="copyright" content="(C) Copyright 2018"><meta name="DC.rights.owner" content="(C) Copyright 2018"><meta name="DC.Type" content="concept"><meta name="description" content="The DITA Open Toolkit uses various recent DITA features in the project documentation."><meta name="DC.Relation" scheme="URI" content="../reference/DITA_spec-support.html"><meta name="DC.Format" content="HTML5"><meta name="DC.Identifier" content="ID"><link rel="stylesheet" type="text/css" href="../css/commonltr.css"><link rel="stylesheet" type="text/css" href="../css/dita-ot-doc.css"><title>DITA features in the documentation</title></head><body id="ID"><header role="banner"><div class="header">
  4. <p>DITA Open Toolkit</p>
  5. <hr>
  6. </div></header><nav role="toc"><ul><li><a href="../index.html">DITA Open Toolkit 3.0</a></li><li><a href="../release-notes/index.html">Release Notes</a></li><li><a href="../topics/installing-client.html">Installing DITA-OT</a></li><li><a href="../topics/alternative-input-formats.html">Authoring formats</a></li><li><a href="../topics/building-output.html">Building output</a></li><li><a href="../parameters/index.html">Setting parameters</a></li><li><a href="../topics/extending-the-ot.html">Customizing DITA-OT</a></li><li><a href="../topics/troubleshooting-overview.html">Troubleshooting</a></li><li><a href="../reference/index.html">Reference</a><ul><li><a href="../reference/architecture.html">DITA-OT architecture</a></li><li><a href="../reference/DITA_spec-support.html">DITA specification support</a><ul><li><a href="../reference/DITA_v1-2-support.html">DITA 1.2 support</a></li><li><a href="../reference/DITA_v1-3-support.html">DITA 1.3 support</a></li><li><a href="../reference/implementation-dependent-features.html">Implementation-dependent features</a></li><li><a href="../reference/extended-functionality.html">Coderef extensions</a></li><li class="active"><a href="../reference/DITA-features-in-docs.html">DITA features in docs</a></li></ul></li><li><a href="../reference/java-api.html">Java API</a></li><li><a href="../reference/license.html">License</a></li></ul></li><li><a href="../topics/dita-and-dita-ot-resources.html">Resources</a></li></ul></nav><main role="main"><article role="article" aria-labelledby="ariaid-title1">
  7. <h1 class="title topictitle1" id="ariaid-title1">DITA features in the documentation</h1>
  8. <div class="body conbody"><p class="shortdesc">The DITA Open Toolkit uses various recent DITA features in the project documentation.</p>
  9. <p class="p">The
  10. <a class="xref" href="https://github.com/dita-ot/docs" target="_blank">source files</a> for the DITA-OT
  11. documentation include examples of the following DITA features (among others):</p>
  12. <ul class="ul">
  13. <li class="li">subjectScheme classification for controlling available attributes</li>
  14. <li class="li">profiling and branch filtering (novice/expert content)</li>
  15. <li class="li">extending topics with conref push</li>
  16. <li class="li">keys and key references</li>
  17. <li class="li">XML mention domain</li>
  18. </ul>
  19. <section class="section"><h2 class="title sectiontitle">Subject schemes </h2>
  20. <p class="p">Various topics, sections and elements in the docs are profiled by audience:</p>
  21. <div class="p"><pre class="pre codeblock"><code>&lt;li id="novice-variables-last" audience="novice"&gt;
  22. &lt;p id="common-format-info"&gt;
  23. &lt;varname&gt;format&lt;/varname&gt; is the output format (transformation type).
  24. This argument corresponds to the common parameter &lt;parmname&gt;transtype&lt;/parmname&gt;.
  25. Use the same values as for the &lt;parmname&gt;transtype&lt;/parmname&gt; build parameter,
  26. for example, &lt;option&gt;html5&lt;/option&gt; or &lt;option&gt;pdf&lt;/option&gt;.&lt;/p&gt;
  27. &lt;/li&gt;</code></pre></div>
  28. <p class="p">An “audience” subject scheme controls the values that are available for the <code class="keyword markupname xmlatt">@audience</code>
  29. attribute:</p>
  30. <div class="p"><pre class="pre codeblock"><code> &lt;subjectdef keys="audience"&gt;
  31. &lt;subjectdef keys="novice"/&gt;
  32. &lt;subjectdef keys="expert"/&gt;
  33. &lt;subjectdef keys="xslt-customizer"/&gt;
  34. &lt;/subjectdef&gt;</code></pre></div>
  35. </section>
  36. <section class="section"><h2 class="title sectiontitle">Branch filtering: re-using profiled content</h2>
  37. </section>
  38. <section class="section">
  39. <p class="p"><cite class="cite">Installing DITA-OT</cite> pulls a subset of the build description from <cite class="cite">using the
  40. <span class="keyword cmdname">dita</span> command</cite>, filtered to display only content deemed suitable for novice users
  41. under
  42. <a class="xref" href="../topics/first-build-using-dita-command.html" title="You can generate output using the DITA Open Toolkit dita command-line tool. Build parameters can be specified on the command line or with .properties files.">Building output</a>:</p>
  43. <div class="p"><pre class="pre codeblock"><code> &lt;topicref href="using-dita-command.dita" keys="first-build-using-dita-command" locktitle="yes"&gt;
  44. &lt;topicmeta&gt;
  45. &lt;navtitle&gt;Building output&lt;/navtitle&gt;
  46. &lt;/topicmeta&gt;
  47. &lt;ditavalref href="../resources/novice.ditaval"&gt;
  48. &lt;ditavalmeta&gt;
  49. &lt;dvrResourcePrefix&gt;first-build-&lt;/dvrResourcePrefix&gt;
  50. &lt;/ditavalmeta&gt;
  51. &lt;/ditavalref&gt;
  52. &lt;/topicref&gt;</code></pre></div>
  53. <p class="p">The same content appears later in
  54. <a class="xref" href="../topics/build-using-dita-command.html" title="You can generate output using the DITA Open Toolkit dita command-line tool. Build parameters can be specified on the command line or with .properties files.">Using the dita command</a> with additional information on arguments, options and examples.</p>
  55. <div class="p"><pre class="pre codeblock"><code> &lt;topicref href="using-dita-command.dita" keys="build-using-dita-command" locktitle="yes"&gt;
  56. &lt;topicmeta&gt;
  57. &lt;navtitle&gt;Using the &lt;cmdname&gt;dita&lt;/cmdname&gt; command&lt;/navtitle&gt;
  58. &lt;/topicmeta&gt;
  59. &lt;ditavalref href="../resources/expert.ditaval"&gt;
  60. &lt;ditavalmeta&gt;
  61. &lt;dvrResourcePrefix&gt;build-&lt;/dvrResourcePrefix&gt;
  62. &lt;/ditavalmeta&gt;
  63. &lt;/ditavalref&gt;</code></pre></div>
  64. </section>
  65. <section class="section"><h2 class="title sectiontitle">Conref push</h2>
  66. </section>
  67. <section class="section">
  68. <p class="p">The docs build uses the conref push mechanism (with the <code class="ph codeph">pushreplace</code>, <code class="ph codeph">mark</code>,
  69. and <code class="ph codeph">pushafter</code>
  70. <a class="xref" href="http://docs.oasis-open.org/dita/dita/v1.3/errata01/os/complete/part1-base/langRef/attributes/theconactionattribute.html" target="_blank">conactions</a>) to extend the parameter descriptions embedded in the
  71. default plug-ins:</p>
  72. <div class="p"><pre class="pre codeblock"><code>&lt;plentry id="args.csspath"&gt;
  73. &lt;pt&gt;
  74. &lt;parmname&gt;args.csspath&lt;/parmname&gt;
  75. &lt;/pt&gt;
  76. &lt;pd conaction="pushreplace" conref="parameters-html5.dita#html5/args.csspath.desc"&gt;
  77. &lt;div conref="./ant-parameters-details.dita#base-html/args.csspath.desc"/&gt;
  78. &lt;/pd&gt;
  79. &lt;pd conaction="mark" conref="parameters-html5.dita#html5/args.csspath.desc"/&gt;
  80. &lt;pd conaction="pushafter"&gt;
  81. &lt;div conref="./ant-parameters-details.dita#base-html/args.csspath.details"/&gt;
  82. &lt;/pd&gt;
  83. &lt;/plentry&gt;</code></pre></div>
  84. <p class="p">The pushed content appears in the output after the default description. (See
  85. <a class="xref" href="../parameters/parameters-base-html.html" title="Certain parameters apply to all HTML-based transformation types: HTML5, XHTML, HTML&nbsp;Help, Eclipse help, and TocJS.">HTML-based output parameters</a>.)</p>
  86. <div class="note tip note_tip"><span class="note__title">Tip:</span> You could also use the same mechanism to extend the documentation with custom information that
  87. applies only to your company's toolkit distribution.</div>
  88. </section>
  89. <section class="section"><h2 class="title sectiontitle">Keys and key references</h2>
  90. </section>
  91. <section class="section">
  92. <p class="p">The <code class="ph codeph">key-definitions.ditamap</code> defines keys for version references, re-usable links, etc.</p>
  93. <p class="p">This key definition defines the maintenance release version:</p>
  94. <div class="p"><pre class="pre codeblock"><code> &lt;keydef keys="maintenance-version"&gt;
  95. &lt;topicmeta&gt;
  96. &lt;keywords&gt;
  97. &lt;keyword&gt;3.0.4&lt;/keyword&gt;
  98. &lt;/keywords&gt;
  99. &lt;/topicmeta&gt;
  100. &lt;/keydef&gt;</code></pre></div>
  101. <p class="p">In topics, the keyword is used in place of hard-coded version references:</p>
  102. <pre class="pre codeblock"><code>&lt;title&gt;DITA Open Toolkit &lt;keyword keyref="maintenance-version"/&gt; Release Notes&lt;/title&gt;</code></pre>
  103. </section>
  104. <section class="section"><h2 class="title sectiontitle">XML mention domain</h2>
  105. </section>
  106. <section class="section">
  107. <p class="p">The docs use the
  108. <a class="xref" href="http://docs.oasis-open.org/dita/dita/v1.3/os/part3-all-inclusive/langRef/containers/xml-mention-domain.html#xml-mention-domain" target="_blank">XML mention domain</a> to mark up XML elements and attributes:</p>
  109. <pre class="pre codeblock"><code>&lt;li id="1777"&gt;
  110. DITA 1.3: Initial support has been added for the &lt;xmlatt&gt;orient&lt;/xmlatt&gt;
  111. attribute on &lt;xmlelement&gt;table&lt;/xmlelement&gt; elements. These changes allow
  112. Antenna House Formatter to render tables in landscape mode when the
  113. &lt;xmlatt&gt;orient&lt;/xmlatt&gt; attribute is set to &lt;option&gt;land&lt;/option&gt;. […]
  114. &lt;/li&gt;</code></pre>
  115. <p class="p">When the toolkit generates output for the sample above:</p>
  116. <ul class="ul">
  117. <li class="li">the XML element name is wrapped in angle brackets as <code class="keyword markupname xmlelement">&lt;table&gt;</code>
  118. </li>
  119. <li class="li">the attribute name is prefixed with an “at” sign as <code class="keyword markupname xmlatt">@orient</code></li>
  120. </ul>
  121. </section>
  122. </div>
  123. <nav role="navigation" class="related-links"><div class="familylinks"><div class="parentlink"><strong>Parent topic:</strong> <a class="link" href="../reference/DITA_spec-support.html" title="DITA Open Toolkit 3.0 supports all versions of the OASIS DITA specification, including 1.0, 1.1, 1.2, and 1.3.">DITA specification support</a></div></div></nav></article></main></body></html>