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]

Re: [docbook-apps] <literallayout> rendered with lots of internal whitespace


On Fri, Sep 05, 2003 at 01:16:28PM -0400, Robert P. J. Day wrote:
> On Fri, 5 Sep 2003, Bob Stayton wrote:
> 
> > > </literallayout>
> > > 
> > >   an absolutely stock, non-customized PDF rendering appears as:
> > > 
> > >            Now          is         the         time
> > >             for       all        good           men
> > >         to       come      to         the       aid
> > >                of             their           party.
> > > 
> > > in other words, all sorts of inserted whitespace, and left-justified
> > > for no reason that i know of.
> > > 
> > >   OTOH, if i change this ever so slightly to
> > > 
> > > <literallayout class="monospaced">...
> > > 
> > > it's perfect -- courier font, proper indentation:
> > > 
> > >  Now is the time
> > >    for all good men
> > >  to come to the aid
> > >    of their party.
> > > 
> > > 
> > > any reason why a generic literallayout would generate the first
> > > example above?  the example shown in the online docbook TDG is
> > > wrapped inside a <blockquote>, but a <para> is apparently a legal
> > > parent as well, which is what i'm using.
> > 
> > I think this may be a bug in the attribute-set definitions.
> > The 'verbatim.properties' attribute set does not set
> > text-align="start", so FOP reverts to the inherited 
> > text-align="justify".  The 'monospace.verbatim.properties'
> > attribute-set uses 'verbatim.properties' and adds
> > text-align="start".
> > 
> > This seems to have been done intentionally, but I'm not
> > sure why.  I think all of the whitespace preserving
> > properties should be in these attribute-sets.
> > These would include:
> > 
> > text-align='start'
> > wrap-option='no-wrap'
> > white-space-collapse='false'
> > linefeed-treatment="preserve"
> 
> i *thought* i saw what you were referring to, so i just added 
> the "text-align=start" to verbatim.properties, but it didn't seem
> to make a difference with the literallayout rendering.
> 
> so maybe i'll just leave it alone so i don't break it, and i'll
> wait to hear later what the deal is.

Hmm, it worked for me.  I copied the verbatim.properties
attribute-set from fo/param.xsl to a customization layer
and added text-align="start" and now the literallayout
text is left aligned.  Can you check your fo output
to make sure that property got in there?

-- 

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

To unsubscribe from this list, send a post to docbook-apps-unsubscribe@lists.oasis-open.org.


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