Author view adds white-space unintended
Post here questions and problems related to oXygen frameworks/document types.
-
- Posts: 81
- Joined: Mon Mar 05, 2012 5:23 pm
Author view adds white-space unintended
Hi,
I've a problem with white-space handling in Oxygen XML Author. If you have this XML (Snippet, of course):
And this CSS:
results this in this author view (Oxygen 15.2 and 16):

Note, that there is a unintended white-space before the italic text at the beginning of each "Stufe0" tag (tag "Kursivtext" in the xml).
Do you habe a hint, how I could fix it? With
in CSS on "Stufe0" the leading whitespace disappears - but many others problems come up (unintended line breaks etc.).
Thx for every help!
Stefan
I've a problem with white-space handling in Oxygen XML Author. If you have this XML (Snippet, of course):
Code: Select all
<Stufe0 id="W00000153">
<Inhalt>
<Kursivtext>Wakermann</Kursivtext> s. <ref ziel="W00000033">Wackermann</ref>
</Inhalt>
</Stufe0>
<Stufe0 id="W00000154">
<Inhalt>Wakin Jakob, Mautner zu St. Veit am Pflaum <Regestennummer>#0-4959</Regestennummer>
</Inhalt>
</Stufe0>
Code: Select all
Stufe0 {
display: block;
margin: 0.5em 0 0.5em 0;
padding: 0.5em 0 0.5em 0;
border-bottom: 1px solid silver;
}
Inhalt {
display: inline;
-oxy-placeholder-content: "[Hier Text eingeben]";
-oxy-display-tags: none;
}
Kursivtext {
font-style: italic;
-oxy-display-tags: none;
}

Note, that there is a unintended white-space before the italic text at the beginning of each "Stufe0" tag (tag "Kursivtext" in the xml).
Do you habe a hint, how I could fix it? With
Code: Select all
white-space: -oxy-trim-when-ws-only;
Thx for every help!
Stefan
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: Author view adds white-space unintended
Post by alex_jitianu »
Hello Stefan,
From what I understand that extra space remains from the indent inside Inhalt:
Inhalt is mixed (both child elements and text content). It's probably also declared inside the schema as being mixed. Because it's being seen as mixed, that starting indent is considered important and it is normalized instead of being removed altogether. If you use the Pretty Print action from text page on this XML, you will notice that Oxygen doesn't insert an indent inside Inhalt, just because of this reason:
What I'm trying to say is that the indent should not be there in the first place. If you create from scratch an Inhalt element inside Author mode and save, I expect that Inhalt element not to be indented.
Nevertheless, if you already have these indents and want to ignore them, then my suggestion is the same as what you already did, to add -oxy-trim-when-ws-only on Inhalt. Could you show me an example when these setting does bad things? You said something about line breaks. Maybe you could set pre-line on those elements?
Best regards,
Alex
From what I understand that extra space remains from the indent inside Inhalt:
Code: Select all
<Inhalt>
<Kursivtext>
Code: Select all
<Stufe0 id="W00000153">
<Inhalt><Kursivtext>Wakermann</Kursivtext> s. <ref ziel="W00000033">Wackermann</ref></Inhalt>
</Stufe0>
Nevertheless, if you already have these indents and want to ignore them, then my suggestion is the same as what you already did, to add -oxy-trim-when-ws-only on Inhalt. Could you show me an example when these setting does bad things? You said something about line breaks. Maybe you could set pre-line on those elements?
Best regards,
Alex
Return to “SDK-API, Frameworks - Document Types”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service