Re: [xep-support] <PRE> tag like behavior?

From: Alexander Peshkov (
Date: Wed Jun 02 2004 - 08:17:33 PDT

  • Next message: Nikolai Grigoriev: "Re: [xep-support] Suppressing validation errors"

    Hello Chris,

    The common way to achieve <pre>-like effect is:

    <fo:block white-space="pre">
      This text will be formatted as it is,
        with all line-breaks and white spaces.

    Here 'white-space' is a shorthand property. Its value 'pre'
    corresponds to:


    If you need finer control over your preformatted text (e.g. you want
    lines to be wrapped) you may want to set those properties

    Best regards,
    Alexander Peshkov

    CC> Is there an easy (relatively) way to use XEP to create <PRE>-like
    CC> formatted text?

    CC> We currently have an inline element called <examplecode>. When
    CC> rendered through XEP the data is output in monospace bold font.

    CC> If line breaks were required, we would wrap it in para tags.

    CC> The problem we have is that we want to render example code with proper
    CC> indentation. The simple solution (although time consuming for the
    CC> writer), is to create some kind of "tab" formatting tag, and have the
    CC> writer insert the proper number of tabs for indentation. During render
    CC> the tab tag would be rendered into X amount of space per tab.

    CC> Is there an easier way?

    CC> Thanks,
    CC> Chris

    (*) To unsubscribe, send a message with words 'unsubscribe xep-support'
    in the body of the message to from the address
    you are subscribed from.
    (*) By using the Service, you expressly agree to these Terms of Service

    This archive was generated by hypermail 2.1.5 : Wed Jun 02 2004 - 08:31:21 PDT