VirtualBox

source: vbox/trunk/src/libs/dita-ot-1.8.5/docsrc/readme/mapref.xml@ 99507

最後變更 在這個檔案從99507是 98584,由 vboxsync 提交於 2 年 前

Docs: bugref:10302. Setting svn properties of DITA-OT library.

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Author Date Id Revision
檔案大小: 3.9 KB
 
1<?xml version="1.0" encoding="UTF-8"?>
2<!--Arbortext, Inc., 1988-2010, v.4002-->
3<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN"
4 "task.dtd">
5<task id="mapref" xml:lang="en-us">
6<title>Mapref</title>
7<shortdesc>Mapref refers to a special usage of the <tt>&lt;topicref&gt;</tt>
8 element as a reference to another ditamap file. This allows you
9to manage the overall ditamap file more easily. A large ditamap
10file can thus be broken down into several ditamap files, making
11it easier for the user to manage the overall logical structure.
12This mechanism also increases the reusability of those ditamap files.</shortdesc>
13<taskbody>
14<context>You can create references to another ditamap file by setting
15the format attribute to "ditamap" as follows.<note>This usage is often
16referred to as <codeph>mapref</codeph>. A new <codeph>mapref</codeph> element
17is defined in DITA 1.2, which provides a shortcut for this function
18by defaulting the format attribute to "ditamap". However, any topicref
19or topicref specialization may do the same thing by setting the format
20attribute as described.</note></context>
21<steps>
22<step><cmd>Add a <tt>&lt;topicref&gt;</tt> element to your map.</cmd>
23</step>
24<step><cmd>Define the location of the target ditamap file in the href
25attribute. The href takes a standard URI format. Typically it is a
26relative path to the ditamap. </cmd></step>
27<step><cmd>Set format="ditamap".</cmd></step>
28<step importance="optional"><cmd>Add a navigation title in the navtitle
29attribute. </cmd><info>The navtitle attribute on a map reference is
30not used for anything during DITA-OT processing, but is helpful when
31authoring.</info></step>
32</steps>
33<example> <p>For example, if you want to create a reference
34to the <i>samples/mysamp.ditamap</i> file using <tt>sample
35ditamap</tt> as the navigation title, add the following codes
36into the <i>readme.ditamap</i> file.</p><p> <codeblock>&lt;topicref format="ditamap" href="samples/mysample.ditamap" navtitle="sample ditamap"&gt; </codeblock>
37 </p> <p>Now the complete content of the <i>readme.ditamap</i> file
38is shown as follows. <codeblock>
39&lt;?xml version="1.0" encoding="utf-8"?&gt;
40&lt;!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd"&gt;
41&lt;map id="mainDITAreadme" title="DITA Readme map"&gt;
42 &lt;topicref collection-type="family" href="DITA-readme.xml" id="DITA-doc"
43 locktitle="yes" navtitle="DITA-OT Introduction"&gt;
44 &lt;topicref href="DITA-changes.xml" navtitle="DITA release history"/&gt;
45 &lt;topicref format="ditamap" href="samples/mysample.ditamap" navtitle="sample ditamap"/&gt;
46 &lt;/topicref&gt;
47&lt;/map&gt;
48 </codeblock> </p> <p>Assume the file <i>samples/mysample.ditamap</i> is
49defined as follows:<codeblock>
50&lt;?xml version="1.0" encoding="utf-8"?&gt;
51&lt;!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd"&gt;
52&lt;map id="samplemap" title="Sample Ditamap"&gt;
53 &lt;topicref href="..\DITA-relnotes.xml" navtitle="DITA OT Release notes"/&gt;
54 &lt;topicref href="..\DITA-installation.xml" navtitle="Installation"/&gt;
55&lt;/map&gt;
56 </codeblock><?Pub Caret 301?> </p><p>The <i>readme.ditamap</i> file
57can be equivalently expressed by the following map:</p><p>
58 <codeblock>
59&lt;?xml version="1.0" encoding="utf-8"?&gt;
60&lt;!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd"&gt;
61&lt;map id="mainDITAreadme" title="DITA Readme map"&gt;
62 &lt;topicref collection-type="family" href="DITA-readme.xml"
63 id="DITA-doc" locktitle="yes" navtitle="DITA-OT Introduction"&gt;
64 &lt;topicref href="DITA-changes.xml" navtitle="DITA release history"/&gt;
65 &lt;topicref href="DITA-relnotes.xml" navtitle="DITA OT Release notes"/&gt;
66 &lt;topicref href="DITA-installation.xml" navtitle="Installation"/&gt;
67 &lt;/topicref&gt;
68&lt;/map&gt;
69 </codeblock></p></example>
70</taskbody>
71</task>
72<?Pub *0000003985?>
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette