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]
Other format: [Raw text]

Centering an equation


Hello,

I'm using the XSL stylesheets version 1.58.1.  I am trying to centre
an <equation> that contains an EPS <mediaobject>.  Using this
construct:

      <equation>
        <mediaobject>
          <imageobject>
            <imagedata format="EPS" fileref="../images/eqn1.eps"
            align="center"/>
          </imageobject>
        </mediaobject>
      </equation>

I get the following FO fragment:

<fo:external-graphic src="url(../images/eqn1.eps)" width="auto"
height="auto" content-width="auto" content-height="auto"
text-align="center"/>

and the surrounding <fo:block> is attribute-less.  XEP renders the
XSLFO with the equation left-justified, and Nikolai Grigoriev on the
xep-support list tells me that this is correct, since the semantics of
text-align is different in <fo:external-graphic>.  Manually adding the
attribute 'text-align="center"' to the surrounding <fo:block>
generated by the stylesheets achieves the desired effect.

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.

Thanks for any advice.


-- 
Paul.

mailto:paulh@logicsquad.net
mailto:paul.hoadley@student.adelaide.edu.au


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