[oXygen-user] Pretty Print <lb/> in Oxygen

Wendell Piez
Wed Dec 17 11:09:16 CST 2014

Syd and Gerrit,

I am so behind! (on old messages to mailing lists) --

In the meantime, until oXygen does everything perfectly, could one
perhaps introduce the LF characters you want (in your mixed content)
using XQuery update (which works in oXygen's XQuery Builder), or
(gasp!) plain-text s/r over the raw XML?

Cheers, Wendell

On Tue, Oct 28, 2014 at 5:06 PM, Syd Bauman <> wrote:
> I agree with Gerrit; while all Andreas says is true, it is not an
> argument against having an option for format-and-indent to
> intelligently insert specific whitespace in front of (or after)
> desired elements. (Not only are we suggesting this as an option, I
> suspect all of us on the "I like this feature" side would agree it
> should be an option that is off by default, for the very reasons
> Andreas articulates :-)
> E.g., adding two new tabs to Options > Preferences / Editor / Format
> / XML / Element Spacing:
>  1) Starts new line:
>     Element names or XPath expressions for which the start-tag (or
>     empty-element tag) should be forced to start on a new line (and
>     then indented appropriately)
>  2) Ends line:
>     Element names or XPath expressions for which the start-tag (or
>     empty-element tag) should be made the last token on a line
> Both lists should start out empty, of course.
> P.S. IIRC, last I checked (years ago) those were not "XPath
>      expressions", they were not even full XSLT patterns, but rather
>      were a very limited set of XSLT patterns. If that is still true,
>      I would strongly recommend changing the wording slightly and
>      putting some pop-up help or information right there.
>> I share Ute's wish for a format-and-indent in the text mode that
>> puts <lb> at the beginning of each line. xml:space does not seem
>> satisfying to me because it prevents Oxygen from doing any
>> format-and-indent. Find/replace is neither very elegant nor will it
>> give the result Syd has described.
>> I admit that the addition of whitespace in mixed content elements
>> where no whitespace exists is generally critical (and I like Oxygen
>> for not doing this!). However, any whitespace preceding or
>> following an <lb> can be treated as insignificant. Even
>> Oxy<lb break="no">gen
>> Oxy
>> <lb break="no">gen
>> are equivalent, except that a little more processing is needed to
>> extract the token "Oxygen" from such an encoding. So I find it
>> responsible to allow Oxygen---on explicit request---to add
>> whitespace befor <lb> elements. At least, it would be nice to get
>> Oxygen to put all the <lb>s at the beginning of the line that
>> *already have* whitespace before them.
> _______________________________________________
> oXygen-user mailing list
> http://www.oxygenxml.com/mailman/listinfo/oxygen-user

Wendell Piez | http://www.wendellpiez.com
XML | XSLT | electronic publishing
Eat Your Vegetables

More information about the oXygen-user mailing list