xml-domain.xsl 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!-- This file is part of the DITA Open Toolkit project.
  3. See the accompanying license.txt file for applicable licenses.-->
  4. <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  5. xmlns:fo="http://www.w3.org/1999/XSL/Format"
  6. version="2.0">
  7. <xsl:template match="*[contains(@class, ' xml-d/xmlelement ')]">
  8. <fo:inline xsl:use-attribute-sets="xmlelement">
  9. <xsl:call-template name="commonattributes"/>
  10. <xsl:text>&lt;</xsl:text>
  11. <xsl:apply-templates/>
  12. <xsl:text>&gt;</xsl:text>
  13. </fo:inline>
  14. </xsl:template>
  15. <xsl:template match="*[contains(@class, ' xml-d/xmlatt ')]">
  16. <fo:inline xsl:use-attribute-sets="xmlatt">
  17. <xsl:call-template name="commonattributes"/>
  18. <xsl:text>@</xsl:text>
  19. <xsl:apply-templates/>
  20. </fo:inline>
  21. </xsl:template>
  22. <xsl:template match="*[contains(@class, ' xml-d/textentity ')]">
  23. <fo:inline xsl:use-attribute-sets="textentity">
  24. <xsl:call-template name="commonattributes"/>
  25. <xsl:text>&amp;</xsl:text>
  26. <xsl:apply-templates/>
  27. <xsl:text>;</xsl:text>
  28. </fo:inline>
  29. </xsl:template>
  30. <xsl:template match="*[contains(@class, ' xml-d/parameterentity ')]">
  31. <fo:inline xsl:use-attribute-sets="parameterentity">
  32. <xsl:call-template name="commonattributes"/>
  33. <xsl:text>%</xsl:text>
  34. <xsl:apply-templates/>
  35. <xsl:text>;</xsl:text>
  36. </fo:inline>
  37. </xsl:template>
  38. <xsl:template match="*[contains(@class, ' xml-d/numcharref ')]">
  39. <fo:inline xsl:use-attribute-sets="numcharref">
  40. <xsl:call-template name="commonattributes"/>
  41. <xsl:text>&amp;#</xsl:text>
  42. <xsl:apply-templates/>
  43. <xsl:text>;</xsl:text>
  44. </fo:inline>
  45. </xsl:template>
  46. <xsl:template match="*[contains(@class, ' xml-d/xmlnsname ')]">
  47. <fo:inline xsl:use-attribute-sets="xmlnsname">
  48. <xsl:call-template name="commonattributes"/>
  49. <xsl:apply-templates/>
  50. </fo:inline>
  51. </xsl:template>
  52. <xsl:template match="*[contains(@class, ' xml-d/xmlpi ')]">
  53. <fo:inline xsl:use-attribute-sets="xmlpi">
  54. <xsl:call-template name="commonattributes"/>
  55. <xsl:apply-templates/>
  56. </fo:inline>
  57. </xsl:template>
  58. </xsl:stylesheet>