On 09/23/2011 02:38 PM, Agnes Clarke wrote:
> I have a simple document format that allows text within a <description>
> element. When I close and reopen the document the text is disrupted by
> the line breaks in the XML - I would expect from prior use of XML Mind
> that the white space should be collapsed to a single space.
>
> Here is my CSS, which does not contain anything unusual:
>
> types, complex-type, field, name, description {
>
> display: block;
>
> padding-bottom: 6px;
>
> }
>
> /*indentation*/
>
> field {
>
> margin-left: 5em;
>
> }
>
> /*titles*/
>
> name {
>
> font-size: 120%;
>
> font-weight: bold;
>
> }
>
> /*Prefix texts*/
>
> field name:before {
>
> content: xpath("../../*[local-name(.) = 'name']") ".";
>
> font-weight: bold;
>
> }
>

This is not related to your CSS, which is fine.

My guess is that your schema specifies that, by default, the 
<description> element has xml:space="preserve"[*] or, may be, one of it 
ancestor elements has by default xml:space="preserve".

Please take a look at the Attributes tool or press Shift-F1 (Help|Show 
Content Model) to check this.



---
[*] Another less common possibility would be declaring the <description> 
element in the preserveSpace configuration element. See 
http://www.xmlmind.com/xmleditor/_distrib/doc/configure/preserveSpace.html


 
--
XMLmind XML Editor Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/xmleditor-support

Reply via email to