migrating-to-2.0.dita 3.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
  3. <!-- This file is part of the DITA Open Toolkit project. See the accompanying LICENSE file for applicable license. -->
  4. <reference id="migrating-to-2.0">
  5. <title>Migrating to release 2.0</title>
  6. <titlealts>
  7. <navtitle>To 2.0</navtitle>
  8. </titlealts>
  9. <shortdesc>In DITA-OT 2.0, XSLT templates were converted to XSLT 2.0, variable typing was implemented, and some older
  10. templates were refactored or removed. In addition, the <cmdname>dita</cmdname> command simplifies distribution of
  11. plugins by allowing installation from a URL.<draft-comment author="staylor">There are likely other changes that
  12. should be noted here. See <xref keyref="2.0-release-notes"/>. </draft-comment>
  13. </shortdesc>
  14. <prolog>
  15. <metadata>
  16. <keywords>
  17. <indexterm><xmlatt>as</xmlatt></indexterm>
  18. <indexterm><cmdname>dita</cmdname> command<indexterm>plug-ins</indexterm></indexterm>
  19. <indexterm>uninstalling</indexterm>
  20. <indexterm>removing<index-see>uninstalling</index-see></indexterm>
  21. <indexterm>deinstalling<index-see>uninstalling</index-see></indexterm>
  22. <indexterm>XSLT<indexterm>2.0</indexterm></indexterm>
  23. <indexterm>Customization directory</indexterm>
  24. </keywords>
  25. </metadata>
  26. </prolog>
  27. <refbody>
  28. <section>
  29. <note>This topic provides a summary of changes in DITA-OT 2.0 that may require modifications to custom stylesheets
  30. or plug-ins. For more information on changes in this release, see the <xref keyref="2.0-release-notes"/>.</note>
  31. </section>
  32. <refbodydiv>
  33. <section>
  34. <title>All transformations — variable typing</title>
  35. <p>XSLT stylesheets were converted to XSLT 2.0. With that change, variable types were also implemented. Plug-ins
  36. that change template variable values will need to make the following changes:</p>
  37. <ul>
  38. <li>Declare the same types defined in the default templates with <xmlatt>as</xmlatt>.</li>
  39. <li>Ensure that the generated values conform to the declared type.</li>
  40. </ul>
  41. </section>
  42. <example>
  43. <p>For example:</p>
  44. <codeblock outputclass="language-xml">&lt;xsl:variable name="urltest">
  45. &lt;xsl:variable name="urltest" <b>as="xs:boolean"</b>></codeblock>
  46. </example>
  47. <section>
  48. <title>All transformations — refactoring</title>
  49. <p>Much of the toolkit code was refactored for release 2.0. Customization changes that were based on a specific
  50. template in a previous version of the toolkit might not work because the modified template is no longer used.
  51. If this is the case, the changes will need to be reimplemented based on the new XSLT templates.</p>
  52. </section>
  53. </refbodydiv>
  54. <section>
  55. <title>HTML5</title>
  56. <p>A new <option>HTML5</option> transformation type has been added. Customizations that previously modified the
  57. XHTML output to generate valid HTML5 should still work, but basing your customization on the new transformation
  58. type might simplify the customization and reduce the work required to maintain compatibility with future
  59. versions of the toolkit.</p>
  60. <note>The <option>HTML5</option> transformation was refactored with release 2.2. Before basing your customization
  61. on the changes in release 2.0, consider whether you might want to move to release 2.2 instead. See <xref
  62. keyref="migrating-to-2.2"/>.</note>
  63. </section>
  64. <section>
  65. <title>Plug-in installation and distribution</title>
  66. <p>Plug-ins can now be installed or uninstalled from a ZIP archive using the new <cmdname>dita</cmdname> command.
  67. Plug-ins can also be installed from a referenced URL. See <xref keyref="dita-command-arguments"/>.</p>
  68. </section>
  69. </refbody>
  70. </reference>