This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: Centering an equation
On Sun, Jan 12, 2003 at 10:36:03PM +1030, Paul A. Hoadley wrote:
> I can't believe I'm about to reply to myself again...
>
> On Sun, Jan 12, 2003 at 09:16:24PM +1030, Paul A. Hoadley wrote:
> > On Sun, Jan 12, 2003 at 07:37:06PM +1030, Paul A. Hoadley wrote:
> >
> > > Is this a stylesheet bug, or, more likely, am I doing something
> > > obviously wrong here? As a followup question, is there a way to get
> > > the stylesheets to insert some top-padding above the included image as
> > > well? Centred or not, it sits right up under the preceding line of
> > > text.
> >
> > I suspect this is the answer to my question:
> >
> > | 2002-12-17 Robert Stayton <bobstayton@users.sourceforge.net>
> > |
> > | * common.xsl: Changed selection of mediaobject to be more
> > | consistent using a separate select.mediaobject.index
> > | template. Also added text-align to block containing
> > | external-graphic in fo output.
> >
> > So I guess I should upgrade and try again. :-)
>
> Just tried 1.59.0. This minimal input:
>
> -------
> <book>
> <chapter>
> <title>Using <application>&am;</application></title>
> <sect1>
> <title>General</title>
> <para>Some text.</para>
> <equation>
> <mediaobject>
> <imageobject>
> <imagedata format="EPS" fileref="../images/eqn1.eps"
> align="center"/>
> </imageobject>
> </mediaobject>
> </equation>
> </sect1>
> </chapter>
> </book>
> -------
>
> still puts 'text-align="center"' in <fo:external-graphic> rather than
> <fo:block>. Bob, can you offer any insight?
Ah, yes, it turns out that a mediaobject inside an equation
element is handled in a separate template in fo/math.xsl.
That template needs to be updated as well to put the
align attribute on the fo:block.
--
Bob Stayton 400 Encinal Street
Publications Architect Santa Cruz, CA 95060
Technical Publications voice: (831) 427-7796
The SCO Group fax: (831) 429-1887
email: bobs@sco.com