l10n.gentext.use.xref.language.xml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <refentry xmlns="http://docbook.org/ns/docbook"
  2. xmlns:xlink="http://www.w3.org/1999/xlink"
  3. xmlns:xi="http://www.w3.org/2001/XInclude"
  4. xmlns:src="http://nwalsh.com/xmlns/litprog/fragment"
  5. xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  6. version="5.0" xml:id="l10n.gentext.use.xref.language">
  7. <refmeta>
  8. <refentrytitle>l10n.gentext.use.xref.language</refentrytitle>
  9. <refmiscinfo class="other" otherclass="datatype">boolean</refmiscinfo>
  10. </refmeta>
  11. <refnamediv>
  12. <refname>l10n.gentext.use.xref.language</refname>
  13. <refpurpose>Use the language of target when generating cross-reference text?</refpurpose>
  14. </refnamediv>
  15. <refsynopsisdiv>
  16. <src:fragment xml:id="l10n.gentext.use.xref.language.frag">
  17. <xsl:param name="l10n.gentext.use.xref.language" select="0"/>
  18. </src:fragment>
  19. </refsynopsisdiv>
  20. <refsection><info><title>Description</title></info>
  21. <para>If non-zero, the language of the target will be used when
  22. generating cross reference text. Usually, the <quote>current</quote>
  23. language is used when generating text (that is, the language of the
  24. element that contains the cross-reference element). But setting this parameter
  25. allows the language of the element <emphasis>pointed to</emphasis> to control
  26. the generated text.</para>
  27. <para>Consider the following example:</para>
  28. <informalexample>
  29. <programlisting>&lt;para lang="en"&gt;See also &lt;xref linkend="chap3"/&gt;.&lt;/para&gt;
  30. </programlisting>
  31. </informalexample>
  32. <para>Suppose that Chapter 3 happens to be written in German.
  33. If <parameter>l10n.gentext.use.xref.language</parameter> is non-zero, the
  34. resulting text will be something like this:</para>
  35. <blockquote>
  36. <para>See also Kapital 3.</para>
  37. </blockquote>
  38. <para>Where the more traditional rendering would be:</para>
  39. <blockquote>
  40. <para>See also Chapter 3.</para>
  41. </blockquote>
  42. </refsection>
  43. </refentry>