Page 1 of 1
[address element] Author view rendering issue
Posted: Tue Apr 13, 2010 5:04 pm
by Tanking
Hello,
We are actually experiencing some issue while rendering the address element in author view using css.
For example:
Code: Select all
<root>
<address>
<street>asdas</street>
<zip>dasdsa</zip>
</address>
<addresse>
<street>asdas</street>
<zip>dasdsa</zip>
</addresse>
</root>
with the following css:
Code: Select all
address, address * {display:inline !important}
addresse, addresse * {display:inline !important}
will indeed display inline the address
e element (or any other element name) but the address element will always be display block and with preserved white-spaces (even using !important force overwrite).
Is the element name address reserved, or with specific properties? If yes, how could we overwrite this specific behavior?
Thanks in advance, and have a nice day.
Re: [address element] Author view rendering issue
Posted: Tue Apr 13, 2010 5:33 pm
by Radu
Hi Jerome,
If an XML element which has an inline display contains elements which have block display, then it will automatically become with block display. So look for the street and zip elements and make them inline if they are defined as having block display.
As for the space-preserve for the address, it can come from a couple of places:
1) If the address has xml:space="preserve" defined on it or on one of its ancestors.
2) If in the CSS file a selector which has the whitespace:pre; property matches the address element or one of its ancestors.
3) Starting with version 11.1 Oxygen also looks by default in the schema associated with the XML to see if xml:space is set as a default attribute for the element with the preserve value.
This is controlled from the Oxygen Preferences->Editor / Pages / Author / Schema aware page by unchecking the Schema aware normalization.... checkbox.
Regards,
Radu
Re: [address element] Author view rendering issue
Posted: Tue Apr 13, 2010 6:28 pm
by Tanking
Hi,
Thank you for the prompt reply. The code I gave you as an example is stand alone. There is no additional css style or schema of any sort.
So the following point are not valid since:
-point 1): there are no references to whitespace in the 2 lines of css.
-point 2): I declare the element address as inline as well as it's content element.
-point 3): the xml file as no reference to a schema. Toggling off the option still give an strange address rendering.
This example gives a strange address element rendering (and correct for the address
e element) on a fresh install of oxygen 11.2 under linux and windows.
Here is a screenshot, with added background-color:red to the address element css:
Radu wrote:
1) If the address has xml:space="preserve" defined on it or on one of its ancestors.
2) If in the CSS file a selector which has the whitespace:pre; property matches the address element or one of its ancestors.
3) Starting with version 11.1 Oxygen also looks by default in the schema associated with the XML to see if xml:space is set as a default attribute for the element with the preserve value.
This is controlled from the Oxygen Preferences->Editor / Pages / Author / Schema aware page by unchecking the Schema aware normalization.... checkbox.
Regards,
Radu
Re: [address element] Author view rendering issue
Posted: Wed Apr 14, 2010 9:51 am
by Radu
Hi Jerome,
There is another place in the Oxygen Preferences where a list of default space-preserve elements is maintained.
The preferences page is called Editor / Format / XML and you should remove from the Preserve space elements list the address element.
Sorry, forgot about this place in the first post.
Regards,
Radu
Re: [address element] Author view rendering issue
Posted: Wed Apr 14, 2010 3:40 pm
by Tanking
Hey Radu,
Thanks a lot! That was indeed what I was looking for.
Have a nice day.