On 08/07/17 16:14, Thibaut Cuvelier wrote:> I am trying to convert LaTeX
subfigures into DocBook,
> [...]
>     <figure xml:id="somename">
>         <title>Main figure</title>
>         <mediaobject xml:id="somename-a">
>             <textobject><simpara>A</simpara></textobject>
>         </mediaobject>
>         <mediaobject xml:id="somename-b">
>             <textobject><simpara>B</simpara></textobject>
>         </mediaobject>
>     </figure>
> </article>

There are several ways to skin this cat. One is exactly what you have.
Depending on the [graphical?] content of the figures, you could have
Two other possibilities are:

        <figure xml:id="somename">
          <title>figure title</title>
          <mediaobject xml:id="somename-a">
            <imageobject>
              <imagedata format="png" fileref="pic-a">
                <info>
                  <title>caption for subfig a</title>
                </info>
              </imagedata>
            </imageobject>
          </mediaobject>
          <mediaobject xml:id="somename-b">
            <imageobject>
              <imagedata format="png" fileref="pic-b"/>
            <textobject>
              <para>Caption for subfig b</para>
            </textobject>
          </mediaobject>
        </figure>

> when putting xml:id at the mediaobject level, I cannot use xref in
> order to point to them:
> 
> Don't know what gentext to create for xref to: "mediaobject"

We always write our own XSLT, so we have a handler to resolve the IDREFs
which point at these, and it's a house business rule to use the
convention of parent id with a hyphen and letter for naming multiple
mediaobject IDs.

///Peter

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to