This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: xrefs for figure naming.


At 07:17 PM 7/8/01, Dave Pawson wrote:

>Now resolved for 'images'.  The title replaces the <caption> content
>of mediaobject, and is working well for cross references. 
>Thanks Norm.
>
>Either I'm abusing it, or its richer than described. I'm starting
>to use it for programlistings, so that I can do the same xref
>stuff. I get the title, automatic numbering etc.
>...
>  (I'm getting that feeling at the back of my neck again.. is there
>another similar wrapper that I've missed, which does for programlisting
>what figure does for mediaobject!)

Before Norm jumps in :-)
Just in case anyone else is as ignorant as I (and wasteful of Norm's work?)

<example id="ex01"><title>this one</title>
<programlisting>
  .....
</programlisting>
</example>

When referenced with <xref linkend="ex01"/>

produces autonumbered output which nicely says

 'When referenced with example x.n this one'
where x is the chapter number,
n is the example number within that chapter.

What other hidden gems are there folks?
TDG isn't explicit, though the DSSSL example does show the listing.

 "D'Oh!" I'm told is the appropriate docbook expression at times
like these :-|

Regards DaveP




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]