hgbook

changeset 640:a13813534ccd

Fix all xref to figs
author Dongsheng Song <dongsheng.song@gmail.com>
date Tue Mar 17 10:43:45 2009 +0800 (2009-03-17)
parents 1a3d882149fd
children 8b73656f95c9
files en/ch02-tour-basic.xml en/ch03-tour-merge.xml en/ch04-concepts.xml en/ch06-collab.xml en/ch09-undo.xml en/ch12-mq.xml
line diff
     1.1 --- a/en/ch02-tour-basic.xml	Mon Mar 16 17:49:05 2009 +0800
     1.2 +++ b/en/ch02-tour-basic.xml	Tue Mar 17 10:43:45 2009 +0800
     1.3 @@ -250,7 +250,8 @@
     1.4  	log</command> is purely a summary; it is missing a lot of
     1.5        detail.</para>
     1.6  
     1.7 -    <para>Figure <xref linkend="fig.tour-basic.history"/> provides a
     1.8 +    <para>Figure <xref endterm="fig.tour-basic.history.caption"
     1.9 +        linkend="fig.tour-basic.history"/> provides a
    1.10        graphical representation of the history of the <filename
    1.11  	class="directory">hello</filename> repository, to make it a
    1.12        little easier to see which direction history is
    1.13 @@ -262,9 +263,9 @@
    1.14        <mediaobject>
    1.15  	<imageobject><imagedata fileref="images/tour-history.png"/></imageobject>
    1.16  	<textobject><phrase>XXX add text</phrase></textobject>
    1.17 -	<caption><para>Graphical history of the <filename
    1.18 -	      class="directory">hello</filename>
    1.19 -	    repository</para></caption>
    1.20 +	<caption><para id="fig.tour-basic.history.caption">Graphical history of
    1.21 +	    the <filename class="directory">hello</filename> repository</para>
    1.22 +	</caption>
    1.23        </mediaobject>
    1.24      </informalfigure>
    1.25  
    1.26 @@ -775,7 +776,8 @@
    1.27        &interaction.tour.parents;
    1.28  
    1.29        <para>If you look back at figure <xref
    1.30 -	  linkend="fig.tour-basic.history"/>,
    1.31 +	   endterm="fig.tour-basic.history.caption" 
    1.32 +	   linkend="fig.tour-basic.history"/>,
    1.33  	you'll see arrows connecting each changeset.  The node that
    1.34  	the arrow leads <emphasis>from</emphasis> in each case is a
    1.35  	parent, and the node that the arrow leads
     2.1 --- a/en/ch03-tour-merge.xml	Mon Mar 16 17:49:05 2009 +0800
     2.2 +++ b/en/ch03-tour-merge.xml	Tue Mar 17 10:43:45 2009 +0800
     2.3 @@ -37,7 +37,7 @@
     2.4      <para>We should now have two copies of
     2.5        <filename>hello.c</filename> with different contents.  The
     2.6        histories of the two repositories have also diverged, as
     2.7 -      illustrated in figure <xref
     2.8 +      illustrated in figure <xref endterm="fig.tour-merge.sep-repos.caption"
     2.9  	linkend="fig.tour-merge.sep-repos"/>.</para>
    2.10  
    2.11      &interaction.tour.merge.cat;
    2.12 @@ -46,7 +46,8 @@
    2.13        <mediaobject>
    2.14  	<imageobject><imagedata fileref="images/tour-merge-sep-repos.png"/></imageobject>
    2.15  	<textobject><phrase>XXX add text</phrase></textobject>
    2.16 -	<caption><para>Divergent recent histories of the <filename
    2.17 +	<caption><para id="fig.tour-merge.sep-repos.caption">Divergent recent
    2.18 +	  histories of the <filename
    2.19  	      class="directory">my-hello</filename> and <filename
    2.20  	      class="directory">my-new-hello</filename>
    2.21  	    repositories</para></caption>
    2.22 @@ -72,23 +73,24 @@
    2.23  	head.</para>
    2.24  
    2.25        <informalfigure id="fig.tour-merge.pull">
    2.26 -	<mediaobject><imageobject><imagedata
    2.27 -				    fileref="images/tour-merge-pull.png"/></imageobject><textobject><phrase>XXX 
    2.28 -	      add text</phrase></textobject>
    2.29 -	  <caption><para>Repository contents after pulling from
    2.30 -	      <filename class="directory">my-hello</filename> into
    2.31 -	      <filename
    2.32 -		class="directory">my-new-hello</filename></para></caption>
    2.33 +	<mediaobject>
    2.34 +	  <imageobject><imagedata fileref="images/tour-merge-pull.png"/></imageobject>
    2.35 +	  <textobject><phrase>XXX add text</phrase></textobject>
    2.36 +	  <caption><para id="fig.tour-merge.pull.caption">Repository contents after
    2.37 +	    pulling from <filename class="directory">my-hello</filename> into
    2.38 +	    <filename class="directory">my-new-hello</filename></para></caption>
    2.39  	</mediaobject>
    2.40        </informalfigure>
    2.41  
    2.42 -      <para>In figure <xref linkend="fig.tour-merge.pull"/>, you can
    2.43 +      <para>In figure <xref endterm="fig.tour-merge.pull.caption"
    2.44 +        linkend="fig.tour-merge.pull"/>, you can
    2.45  	see the effect of the pull from <filename
    2.46  	  class="directory">my-hello</filename> into <filename
    2.47  	  class="directory">my-new-hello</filename>.  The history that
    2.48  	was already present in <filename
    2.49  	  class="directory">my-new-hello</filename> is untouched, but
    2.50  	a new revision has been added.  By referring to figure <xref
    2.51 +	  endterm="fig.tour-merge.sep-repos.caption" 
    2.52  	  linkend="fig.tour-merge.sep-repos"/>, we can see that the
    2.53  	<emphasis>changeset ID</emphasis> remains the same in the new
    2.54  	repository, but the <emphasis>revision number</emphasis> has
    2.55 @@ -119,12 +121,11 @@
    2.56        &interaction.tour.merge.merge;
    2.57  
    2.58        <informalfigure id="fig.tour-merge.merge">
    2.59 -
    2.60 -	<mediaobject><imageobject><imagedata
    2.61 -				    fileref="images/tour-merge-merge.png"/></imageobject><textobject><phrase>XXX 
    2.62 -	      add text</phrase></textobject>
    2.63 -	  <caption><para>Working directory and repository during
    2.64 -	      merge, and following commit</para></caption>
    2.65 +	<mediaobject>
    2.66 +	  <imageobject><imagedata fileref="images/tour-merge-merge.png"/></imageobject>
    2.67 +	  <textobject><phrase>XXX add text</phrase></textobject>
    2.68 +	  <caption><para id="fig.tour-merge.merge.caption">Working directory and
    2.69 +	      repository during merge, and following commit</para></caption>
    2.70  	</mediaobject>
    2.71        </informalfigure>
    2.72  
    2.73 @@ -154,7 +155,7 @@
    2.74  
    2.75        &interaction.tour.merge.tip;
    2.76  
    2.77 -      <para>In figure <xref
    2.78 +      <para>In figure <xref endterm="fig.tour-merge.merge.caption"
    2.79  	  linkend="fig.tour-merge.merge"/>, you can see a
    2.80  	representation of what happens to the working directory during
    2.81  	the merge, and how this affects the repository when the commit
    2.82 @@ -174,16 +175,18 @@
    2.83        to decide how to reconcile the different changes into something
    2.84        coherent.</para>
    2.85  
    2.86 -    <informalfigure>
    2.87 -
    2.88 -      <mediaobject id="fig.tour-merge.conflict">
    2.89 -	<imageobject><imagedata fileref="images/tour-merge-conflict.png"/></imageobject>
    2.90 -	<textobject><phrase>XXX add text</phrase></textobject>
    2.91 -	<caption><para>Conflicting changes to a
    2.92 -	    document</para></caption>      </mediaobject>
    2.93 +    <informalfigure id="fig.tour-merge.conflict">
    2.94 +      <mediaobject>
    2.95 +        <imageobject><imagedata fileref="images/tour-merge-conflict.png"/>
    2.96 +        </imageobject>
    2.97 +        <textobject><phrase>XXX add text</phrase></textobject>
    2.98 +        <caption><para id="fig.tour-merge.conflict.caption">Conflicting
    2.99 +          changes to a document</para></caption>
   2.100 +      </mediaobject>
   2.101      </informalfigure>
   2.102  
   2.103 -    <para>Figure <xref linkend="fig.tour-merge.conflict"/> illustrates
   2.104 +    <para>Figure <xref endterm="fig.tour-merge.conflict.caption"
   2.105 +      linkend="fig.tour-merge.conflict"/> illustrates
   2.106        an instance of two conflicting changes to a document.  We
   2.107        started with a single version of the file; then we made some
   2.108        changes; while someone else made different changes to the same
   2.109 @@ -213,7 +216,8 @@
   2.110  	<command>kdiff3</command>, which I'll use to describe the
   2.111  	features that are common to graphical file merging tools.  You
   2.112  	can see a screenshot of <command>kdiff3</command> in action in
   2.113 -	figure <xref linkend="fig.tour-merge.kdiff3"/>.  The kind of
   2.114 +	figure <xref endterm="fig.tour-merge.kdiff3.caption"
   2.115 +	linkend="fig.tour-merge.kdiff3"/>.  The kind of
   2.116  	merge it is performing is called a <emphasis>three-way
   2.117  	  merge</emphasis>, because there are three different versions
   2.118  	of the file of interest to us.  The tool thus splits the upper
   2.119 @@ -244,12 +248,14 @@
   2.120  	corresponding sections of their respective files.</para>
   2.121  
   2.122        <informalfigure id="fig.tour-merge.kdiff3">
   2.123 -	<mediaobject><imageobject><imagedata width="100%"
   2.124 -				    fileref="images/kdiff3.png"/></imageobject><textobject><phrase>XXX 
   2.125 -	      add text</phrase></textobject>
   2.126 -	  <caption><para>Using <command>kdiff3</command> to merge
   2.127 -	      versions of a file</para></caption>
   2.128 -	</mediaobject>
   2.129 +        <mediaobject>
   2.130 +          <imageobject><imagedata width="100%" fileref="images/kdiff3.png"/>
   2.131 +          </imageobject>
   2.132 +          <textobject><phrase>XXX add text</phrase></textobject>
   2.133 +          <caption><para id="fig.tour-merge.kdiff3.caption">Using
   2.134 +            <command>kdiff3</command> to merge versions of a file</para>
   2.135 +          </caption>
   2.136 +        </mediaobject>
   2.137        </informalfigure>
   2.138  
   2.139        <para>For each conflicting portion of the file, we can choose to
   2.140 @@ -270,7 +276,8 @@
   2.141        <title>A worked example</title>
   2.142  
   2.143        <para>In this example, we will reproduce the file modification
   2.144 -	history of figure <xref linkend="fig.tour-merge.conflict"/>
   2.145 +	history of figure <xref endterm="fig.tour-merge.conflict.caption"
   2.146 +	linkend="fig.tour-merge.conflict"/>
   2.147  	above.  Let's begin by creating a repository with a base
   2.148  	version of our document.</para>
   2.149  
     3.1 --- a/en/ch04-concepts.xml	Mon Mar 16 17:49:05 2009 +0800
     3.2 +++ b/en/ch04-concepts.xml	Tue Mar 17 10:43:45 2009 +0800
     3.3 @@ -47,15 +47,17 @@
     3.4  	file.  The correspondence between a file in the working
     3.5  	directory and the filelog that tracks its history in the
     3.6  	repository is illustrated in figure <xref
     3.7 +	  endterm="fig.concepts.filelog.caption"
     3.8  	  linkend="fig.concepts.filelog"/>.</para>
     3.9  
    3.10        <informalfigure id="fig.concepts.filelog">
    3.11 -	<mediaobject><imageobject><imagedata
    3.12 -				    fileref="images/filelog.png"/></imageobject><textobject><phrase>XXX 
    3.13 -	      add text</phrase></textobject>
    3.14 -	  <caption><para>Relationships between files in working
    3.15 -	      directory and filelogs in
    3.16 -	      repository</para></caption></mediaobject>
    3.17 +        <mediaobject>
    3.18 +          <imageobject><imagedata fileref="images/filelog.png"/></imageobject>
    3.19 +          <textobject><phrase>XXX add text</phrase></textobject>
    3.20 +          <caption><para id="fig.concepts.filelog.caption">Relationships between
    3.21 +            files in working directory and filelogs in repository</para>
    3.22 +          </caption>
    3.23 +        </mediaobject>
    3.24        </informalfigure>
    3.25  
    3.26      </sect2>
    3.27 @@ -97,14 +99,16 @@
    3.28  	manifest.  A revision of the manifest stores a pointer to a
    3.29  	single revision of each filelog tracked when that changeset
    3.30  	was created.  These relationships are illustrated in figure
    3.31 -	<xref linkend="fig.concepts.metadata"/>.</para>
    3.32 +	<xref endterm="fig.concepts.metadata.caption"
    3.33 +	  linkend="fig.concepts.metadata"/>.</para>
    3.34  
    3.35        <informalfigure id="fig.concepts.metadata">
    3.36 -	<mediaobject><imageobject><imagedata
    3.37 -				    fileref="images/metadata.png"/></imageobject><textobject><phrase>XXX 
    3.38 -	      add text</phrase></textobject><caption><para>Metadata
    3.39 -	      relationships</para></caption>
    3.40 -	</mediaobject>
    3.41 +        <mediaobject>
    3.42 +          <imageobject><imagedata fileref="images/metadata.png"/></imageobject>
    3.43 +          <textobject><phrase>XXX add text</phrase></textobject>
    3.44 +          <caption><para id="fig.concepts.metadata.caption">Metadata
    3.45 +            relationships</para></caption>
    3.46 +        </mediaobject>
    3.47        </informalfigure>
    3.48  
    3.49        <para>As the illustration shows, there is
    3.50 @@ -185,11 +189,12 @@
    3.51  	longer it takes to reconstruct a particular revision.</para>
    3.52  
    3.53        <informalfigure id="fig.concepts.snapshot">
    3.54 -	<mediaobject><imageobject><imagedata
    3.55 -				    fileref="images/snapshot.png"/></imageobject><textobject><phrase>XXX 
    3.56 -	      add text</phrase></textobject><caption><para>Snapshot of
    3.57 -	      a revlog, with incremental
    3.58 -	      deltas</para></caption></mediaobject>
    3.59 +        <mediaobject>
    3.60 +          <imageobject><imagedata fileref="images/snapshot.png"/></imageobject>
    3.61 +          <textobject><phrase>XXX add text</phrase></textobject>
    3.62 +          <caption><para id="fig.concepts.snapshot.caption">Snapshot of
    3.63 +            a revlog, with incremental deltas</para></caption>
    3.64 +        </mediaobject>
    3.65        </informalfigure>
    3.66  
    3.67        <para>The innovation that Mercurial applies to this problem is
    3.68 @@ -201,7 +206,8 @@
    3.69  	quickly.  This approach works so well that it has since been
    3.70  	copied by several other revision control systems.</para>
    3.71  
    3.72 -      <para>Figure <xref linkend="fig.concepts.snapshot"/> illustrates
    3.73 +      <para>Figure <xref endterm="fig.concepts.snapshot.caption"
    3.74 +          linkend="fig.concepts.snapshot"/> illustrates
    3.75  	the idea.  In an entry in a revlog's index file, Mercurial
    3.76  	stores the range of entries from the data file that it must
    3.77  	read to reconstruct a particular revision.</para>
    3.78 @@ -273,7 +279,8 @@
    3.79        <quote>there is no parent here</quote>.  This hash is simply a
    3.80        string of zeroes.</para>
    3.81  
    3.82 -    <para>In figure <xref linkend="fig.concepts.revlog"/>, you can see
    3.83 +    <para>In figure <xref endterm="fig.concepts.revlog.caption"
    3.84 +        linkend="fig.concepts.revlog"/>, you can see
    3.85        an example of the conceptual structure of a revlog.  Filelogs,
    3.86        manifests, and changelogs all have this same structure; they
    3.87        differ only in the kind of data stored in each delta or
    3.88 @@ -289,9 +296,12 @@
    3.89        revision IDs in its parent slots.</para>
    3.90  
    3.91      <informalfigure id="fig.concepts.revlog">
    3.92 -      <mediaobject><imageobject><imagedata
    3.93 -				  fileref="images/revlog.png"/></imageobject><textobject><phrase>XXX 
    3.94 -	    add text</phrase></textobject></mediaobject>
    3.95 +      <mediaobject>
    3.96 +        <imageobject><imagedata fileref="images/revlog.png"/></imageobject>
    3.97 +        <textobject><phrase>XXX add text</phrase></textobject>        
    3.98 +	<caption><para id="fig.concepts.revlog.caption">Revision in revlog</para>
    3.99 +	</caption>
   3.100 +      </mediaobject>
   3.101      </informalfigure>
   3.102  
   3.103    </sect1>
   3.104 @@ -338,25 +348,29 @@
   3.105  	  changeset</emphasis> when you perform a commit.</para>
   3.106  
   3.107        <informalfigure id="fig.concepts.wdir">
   3.108 -	<mediaobject><imageobject><imagedata
   3.109 -				    fileref="images/wdir.png"/></imageobject><textobject><phrase>XXX 
   3.110 -	      add text</phrase></textobject><caption><para>The working
   3.111 -	      directory can have two
   3.112 -	      parents</para></caption></mediaobject>
   3.113 +        <mediaobject>
   3.114 +          <imageobject><imagedata fileref="images/wdir.png"/></imageobject>
   3.115 +          <textobject><phrase>XXX add text</phrase></textobject>
   3.116 +          <caption><para id="fig.concepts.wdir.caption">The working
   3.117 +            directory can have two parents</para></caption>
   3.118 +        </mediaobject>
   3.119        </informalfigure>
   3.120  
   3.121 -      <para>Figure <xref linkend="fig.concepts.wdir"/> shows the
   3.122 +      <para>Figure <xref endterm="fig.concepts.wdir.caption"
   3.123 +          linkend="fig.concepts.wdir"/> shows the
   3.124  	normal state of the working directory, where it has a single
   3.125  	changeset as parent.  That changeset is the
   3.126  	<emphasis>tip</emphasis>, the newest changeset in the
   3.127  	repository that has no children.</para>
   3.128  
   3.129        <informalfigure id="fig.concepts.wdir-after-commit">
   3.130 -	<mediaobject><imageobject><imagedata
   3.131 -				    fileref="images/wdir-after-commit.png"/></imageobject><textobject><phrase>XXX 
   3.132 -	      add text</phrase></textobject><caption><para>The working
   3.133 -	      directory gains new parents after a
   3.134 -	      commit</para></caption></mediaobject>
   3.135 +        <mediaobject>
   3.136 +          <imageobject><imagedata fileref="images/wdir-after-commit.png"/>
   3.137 +          </imageobject>
   3.138 +          <textobject><phrase>XXX add text</phrase></textobject>
   3.139 +          <caption><para id="fig.concepts.wdir-after-commit.caption">The working
   3.140 +            directory gains new parents after a commit</para></caption>
   3.141 +        </mediaobject>
   3.142        </informalfigure>
   3.143  
   3.144        <para>It's useful to think of the working directory as
   3.145 @@ -370,7 +384,8 @@
   3.146        <para>After a commit, Mercurial will update the parents of the
   3.147  	working directory, so that the first parent is the ID of the
   3.148  	new changeset, and the second is the null ID.  This is shown
   3.149 -	in figure <xref linkend="fig.concepts.wdir-after-commit"/>.
   3.150 +	in figure <xref endterm="fig.concepts.wdir-after-commit.caption"
   3.151 +	  linkend="fig.concepts.wdir-after-commit"/>.
   3.152  	Mercurial
   3.153  	doesn't touch any of the files in the working directory when
   3.154  	you commit; it just modifies the dirstate to note its new
   3.155 @@ -389,14 +404,17 @@
   3.156  	interested in, and then examine the files in the working
   3.157  	directory directly to see their contents as they were when you
   3.158  	committed that changeset.  The effect of this is shown in
   3.159 -	figure <xref linkend="fig.concepts.wdir-pre-branch"/>.</para>
   3.160 +	figure <xref endterm="fig.concepts.wdir-pre-branch.caption"
   3.161 +	  linkend="fig.concepts.wdir-pre-branch"/>.</para>
   3.162  
   3.163        <informalfigure id="fig.concepts.wdir-pre-branch">
   3.164 -	<mediaobject><imageobject><imagedata
   3.165 -				    fileref="images/wdir-pre-branch.png"/></imageobject><textobject><phrase>XXX 
   3.166 -	      add text</phrase></textobject><caption><para>The working
   3.167 -	      directory, updated to an older
   3.168 -	      changeset</para></caption></mediaobject>
   3.169 +        <mediaobject>
   3.170 +          <imageobject><imagedata fileref="images/wdir-pre-branch.png"/>
   3.171 +          </imageobject>
   3.172 +          <textobject><phrase>XXX add text</phrase></textobject>
   3.173 +          <caption><para id="fig.concepts.wdir-pre-branch.caption">The working
   3.174 +            directory, updated to an older changeset</para></caption>
   3.175 +        </mediaobject>
   3.176        </informalfigure>
   3.177  
   3.178        <para>Having updated the working directory to an older
   3.179 @@ -408,14 +426,17 @@
   3.180  	contains two changesets that have no children; we call these
   3.181  	<emphasis>heads</emphasis>.  You can see the structure that
   3.182  	this creates in figure <xref
   3.183 +	  endterm="fig.concepts.wdir-branch.caption"
   3.184  	  linkend="fig.concepts.wdir-branch"/>.</para>
   3.185  
   3.186        <informalfigure id="fig.concepts.wdir-branch">
   3.187 -	<mediaobject><imageobject><imagedata
   3.188 -				    fileref="images/wdir-branch.png"/></imageobject><textobject><phrase>XXX 
   3.189 -	      add text</phrase></textobject><caption><para>After a
   3.190 -	      commit made while synced to an older
   3.191 -	      changeset</para></caption></mediaobject>
   3.192 +        <mediaobject>
   3.193 +          <imageobject><imagedata fileref="images/wdir-branch.png"/>
   3.194 +          </imageobject>
   3.195 +          <textobject><phrase>XXX add text</phrase></textobject>
   3.196 +          <caption><para id="fig.concepts.wdir-branch.caption">After a
   3.197 +            commit made while synced to an older changeset</para></caption>
   3.198 +        </mediaobject>
   3.199        </informalfigure>
   3.200  
   3.201        <note>
   3.202 @@ -449,13 +470,17 @@
   3.203  	command, Mercurial leaves the first parent of the working
   3.204  	directory unchanged, and sets the second parent to the
   3.205  	changeset you're merging with, as shown in figure <xref
   3.206 +	  endterm="fig.concepts.wdir-merge.caption" 
   3.207  	  linkend="fig.concepts.wdir-merge"/>.</para>
   3.208  
   3.209        <informalfigure id="fig.concepts.wdir-merge">
   3.210 -	<mediaobject><imageobject><imagedata
   3.211 -				    fileref="images/wdir-merge.png"/></imageobject><textobject><phrase>XXX 
   3.212 -	      add text</phrase></textobject><caption><para>Merging two
   3.213 -	      heads</para></caption></mediaobject>
   3.214 +        <mediaobject>
   3.215 +          <imageobject><imagedata fileref="images/wdir-merge.png"/>
   3.216 +          </imageobject>
   3.217 +          <textobject><phrase>XXX add text</phrase></textobject>
   3.218 +          <caption><para id="fig.concepts.wdir-merge.caption">Merging two
   3.219 +            heads</para></caption>
   3.220 +        </mediaobject>
   3.221        </informalfigure>
   3.222  
   3.223        <para>Mercurial also has to modify the working directory, to
   3.224 @@ -582,8 +607,8 @@
   3.225  
   3.226        <para>Appending to files isn't the whole story when it comes to
   3.227  	guaranteeing that a reader won't see a partial write.  If you
   3.228 -	recall figure <xref linkend="fig.concepts.metadata"/>,
   3.229 -	revisions in the
   3.230 +	recall figure <xref endterm="fig.concepts.metadata.caption"
   3.231 +	linkend="fig.concepts.metadata"/>, revisions in the
   3.232  	changelog point to revisions in the manifest, and revisions in
   3.233  	the manifest point to revisions in filelogs.  This hierarchy
   3.234  	is deliberate.</para>
     4.1 --- a/en/ch06-collab.xml	Mon Mar 16 17:49:05 2009 +0800
     4.2 +++ b/en/ch06-collab.xml	Tue Mar 17 10:43:45 2009 +0800
     4.3 @@ -271,10 +271,13 @@
     4.4  	isolated from developments on other branches.</para>
     4.5  
     4.6        <informalfigure id="fig.collab.feature-branches">
     4.7 -	<mediaobject><imageobject><imagedata
     4.8 -				    fileref="images/feature-branches.png"/></imageobject><textobject><phrase>XXX 
     4.9 -	      add text</phrase></textobject><caption><para>Feature
    4.10 -	      branches</para></caption></mediaobject>
    4.11 +        <mediaobject>
    4.12 +          <imageobject><imagedata fileref="images/feature-branches.png"/>
    4.13 +          </imageobject>
    4.14 +          <textobject><phrase>XXX add text</phrase></textobject>
    4.15 +          <caption><para id="fig.collab.feature-branches.caption">Feature
    4.16 +            branches</para></caption>
    4.17 +        </mediaobject>
    4.18        </informalfigure>
    4.19  
    4.20        <para>When a particular feature is deemed to be in suitable
     5.1 --- a/en/ch09-undo.xml	Mon Mar 16 17:49:05 2009 +0800
     5.2 +++ b/en/ch09-undo.xml	Tue Mar 17 10:43:45 2009 +0800
     5.3 @@ -354,18 +354,21 @@
     5.4  	that <command role="hg-cmd">hg backout</command> has created
     5.5  	is a child of the changeset we backed out.  It's easier to see
     5.6  	this in figure <xref
     5.7 -	  linkend="fig.undo.backout"/>, which presents a graphical
     5.8 +	  endterm="fig.undo.backout.caption" linkend="fig.undo.backout"/>,
     5.9 +	which presents a graphical
    5.10  	view of the change history.  As you can see, the history is
    5.11  	nice and linear.</para>
    5.12  
    5.13        <informalfigure id="fig.undo.backout">
    5.14 -	<mediaobject><imageobject><imagedata
    5.15 -				    fileref="images/undo-simple.png"/></imageobject><textobject><phrase>XXX 
    5.16 -	      add text</phrase></textobject><caption><para>Backing out
    5.17 -	      a change using the <command role="hg-cmd">hg
    5.18 -		backout</command>
    5.19 -	      command</para></caption></mediaobject>
    5.20 -	
    5.21 +        <mediaobject>
    5.22 +          <imageobject><imagedata fileref="images/undo-simple.png"/>
    5.23 +          </imageobject>
    5.24 +          <textobject><phrase>XXX add text</phrase></textobject>
    5.25 +          <caption><para id="fig.undo.backout.caption">Backing out
    5.26 +            a change using the 
    5.27 +            <command role="hg-cmd">hg backout</command>
    5.28 +            command</para></caption>
    5.29 +      </mediaobject>
    5.30        </informalfigure>
    5.31  
    5.32      </sect2>
    5.33 @@ -393,6 +396,7 @@
    5.34        &interaction.backout.non-tip.cat;
    5.35  
    5.36        <para>As the graphical history in figure <xref
    5.37 +	  endterm="fig.undo.backout-non-tip.caption"
    5.38  	  linkend="fig.undo.backout-non-tip"/> illustrates, Mercurial
    5.39  	actually commits <emphasis>two</emphasis> changes in this kind
    5.40  	of situation (the box-shaped nodes are the ones that Mercurial
    5.41 @@ -407,12 +411,14 @@
    5.42  	second merge automatically!</para>
    5.43  
    5.44        <informalfigure id="fig.undo.backout-non-tip">
    5.45 -	<mediaobject><imageobject><imagedata
    5.46 -				    fileref="images/undo-non-tip.png"/></imageobject><textobject><phrase>XXX 
    5.47 -	      add text</phrase></textobject><caption><para>Automated
    5.48 -	      backout of a non-tip change using the <command
    5.49 -		role="hg-cmd">hg backout</command>
    5.50 -	      command</para></caption></mediaobject>
    5.51 +        <mediaobject>
    5.52 +          <imageobject><imagedata fileref="images/undo-non-tip.png"/>
    5.53 +          </imageobject>
    5.54 +          <textobject><phrase>XXX add text</phrase></textobject>
    5.55 +          <caption><para id="fig.undo.backout-non-tip.caption">Automated
    5.56 +            backout of a non-tip change using the
    5.57 +            <command role="hg-cmd">hg backout</command> command</para></caption>
    5.58 +        </mediaobject>
    5.59        </informalfigure>
    5.60  
    5.61        <para>The result is that you end up <quote>back where you
    5.62 @@ -465,6 +471,7 @@
    5.63  
    5.64        <para>Again, it's easier to see what has happened by looking at
    5.65  	a graph of the revision history, in figure <xref
    5.66 +	  endterm="fig.undo.backout-manual.caption"
    5.67  	  linkend="fig.undo.backout-manual"/>.  This makes it clear
    5.68  	that when we use <command role="hg-cmd">hg backout</command>
    5.69  	to back out a change other than the tip, Mercurial adds a new
    5.70 @@ -472,13 +479,14 @@
    5.71  	box-shaped).</para>
    5.72  
    5.73        <informalfigure id="fig.undo.backout-manual">
    5.74 -	<mediaobject><imageobject><imagedata
    5.75 -				    fileref="images/undo-manual.png"/></imageobject><textobject><phrase>XXX 
    5.76 -	      add text</phrase></textobject><caption><para>Backing out
    5.77 -	      a change using the <command role="hg-cmd">hg
    5.78 -		backout</command>
    5.79 -	      command</para></caption></mediaobject>
    5.80 -	
    5.81 +        <mediaobject>
    5.82 +          <imageobject><imagedata fileref="images/undo-manual.png"/>
    5.83 +          </imageobject>
    5.84 +          <textobject><phrase>XXX add text</phrase></textobject>
    5.85 +          <caption><para id="fig.undo.backout-manual.caption">Backing out a
    5.86 +            change using the <command role="hg-cmd">hg backout</command>
    5.87 +            command</para></caption>
    5.88 +        </mediaobject>
    5.89        </informalfigure>
    5.90  
    5.91        <para>After the <command role="hg-cmd">hg backout</command>
    5.92 @@ -509,14 +517,17 @@
    5.93  
    5.94        <para>Afterwards, the graphical history of our repository looks
    5.95  	like figure
    5.96 -	<xref linkend="fig.undo.backout-manual-merge"/>.</para>
    5.97 +	<xref endterm="fig.undo.backout-manual-merge.caption"
    5.98 +	  linkend="fig.undo.backout-manual-merge"/>.</para>
    5.99  
   5.100        <informalfigure id="fig.undo.backout-manual-merge">
   5.101 -	<mediaobject><imageobject><imagedata
   5.102 -				    fileref="images/undo-manual-merge.png"/></imageobject><textobject><phrase>XXX 
   5.103 -	      add text</phrase></textobject><caption><para>Manually
   5.104 -	      merging a backout change</para></caption></mediaobject>
   5.105 -	
   5.106 +        <mediaobject>
   5.107 +          <imageobject><imagedata fileref="images/undo-manual-merge.png"/>
   5.108 +          </imageobject>
   5.109 +          <textobject><phrase>XXX add text</phrase></textobject>
   5.110 +          <caption><para id="fig.undo.backout-manual-merge.caption">Manually
   5.111 +            merging a backout change</para></caption>
   5.112 +        </mediaobject>
   5.113        </informalfigure>
   5.114  
   5.115      </sect2>
     6.1 --- a/en/ch12-mq.xml	Mon Mar 16 17:49:05 2009 +0800
     6.2 +++ b/en/ch12-mq.xml	Tue Mar 17 10:43:45 2009 +0800
     6.3 @@ -400,15 +400,16 @@
     6.4  	but the patch no longer has a corresponding changeset in the
     6.5  	repository, and the working directory does not contain the
     6.6  	changes made by the patch.  Figure <xref
     6.7 -	  linkend="fig.mq.stack"/> illustrates
     6.8 +	  endterm="fig.mq.stack.caption" linkend="fig.mq.stack"/> illustrates
     6.9  	the difference between applied and tracked patches.</para>
    6.10  
    6.11        <informalfigure id="fig.mq.stack">
    6.12 -	<mediaobject><imageobject><imagedata
    6.13 -				    fileref="images/mq-stack.png"/></imageobject><textobject><phrase>XXX 
    6.14 -	      add text</phrase></textobject><caption><para>Applied and
    6.15 -	      unapplied patches in the MQ patch
    6.16 -	      stack</para></caption></mediaobject>
    6.17 +        <mediaobject>
    6.18 +          <imageobject><imagedata fileref="images/mq-stack.png"/></imageobject>
    6.19 +          <textobject><phrase>XXX add text</phrase></textobject>
    6.20 +          <caption><para id="fig.mq.stack.caption">Applied and unapplied patches
    6.21 +            in the MQ patch stack</para></caption>
    6.22 +          </mediaobject>
    6.23        </informalfigure>
    6.24  
    6.25        <para>You can reapply an unapplied, or popped, patch using the