<font size=2 face="sans-serif">Hi Wendell,</font>
<br>
<br><font size=2 face="sans-serif">I assume that you're hiding the empty
head element by </font>
<br><font size=2 face="sans-serif"> sect
> head:empty {</font>
<br><font size=2 face="sans-serif">
display: none;</font>
<br><font size=2 face="sans-serif"> }</font>
<br>
<br><font size=2 face="sans-serif">If you use </font>
<br><font size=2 face="sans-serif"> sect
> head:empty {</font>
<br><font size=2 face="sans-serif">
content: "";</font>
<br><font size=2 face="sans-serif"> }</font>
<br><font size=2 face="sans-serif">instead, you should get the desired
behavior: No placeholder is displayed - neither for head nor for sect.
(Still you're able to move the cursor to any position inside to add content.)</font>
<br><font size=2 face="sans-serif">The reason for this lies in the default
logic of the placeholders to be displayed: When there is no content to
be displayed and explicitly content assigned (directly or to :before or
:after) it is hidden. Since there is no value "none" for -oxy-show-placeholder
you can hide it by assigning empty content.</font>
<br>
<br>
<br><font size=2 face="sans-serif">BTW:</font>
<br><font size=2 face="sans-serif">Why do you want to allow sections without
heading? I recently changed our schema to forbid this since </font>
<br><font size=2 face="sans-serif"> <sect></font>
<br><font size=2 face="sans-serif">
<head>Heading</head></font>
<br><font size=2 face="sans-serif">
<p>some text</p></font>
<br><font size=2 face="sans-serif"> </sect></font>
<br><font size=2 face="sans-serif"> <sect></font>
<br><font size=2 face="sans-serif">
<head/></font>
<br><font size=2 face="sans-serif">
<p>some more text</p></font>
<br><font size=2 face="sans-serif"> </sect></font>
<br><font size=2 face="sans-serif">looks in the output identical to</font>
<br><font size=2 face="sans-serif"> <sect></font>
<br><font size=2 face="sans-serif">
<head>Heading</head></font>
<br><font size=2 face="sans-serif">
<p>some text</p></font>
<br><font size=2 face="sans-serif">
<p>some more text</p></font>
<br><font size=2 face="sans-serif"> </sect></font>
<br>
<br>
<br><font size=2 face="sans-serif"><br>
Regards,<br>
<br>
Patrik<br>
<br>
------------------------------------------------------------------<br>
Systemarchitektur & IT-Projekte<br>
Tel: +49 40 33449-1142<br>
Fax: +49 40 33449-1400<br>
E-Mail: patrik.stellmann@gdv-dl.de</font>
<br>
<br>
<br>
<br><font size=1 color=#5f5f5f face="sans-serif">Von:
</font><font size=1 face="sans-serif">Wendell Piez <wapiez@wendellpiez.com></font>
<br><font size=1 color=#5f5f5f face="sans-serif">An:
</font><font size=1 face="sans-serif">"oxygen-user@oxygenxml.com"
<oxygen-user@oxygenxml.com></font>
<br><font size=1 color=#5f5f5f face="sans-serif">Datum:
</font><font size=1 face="sans-serif">06.11.2013 20:55</font>
<br><font size=1 color=#5f5f5f face="sans-serif">Betreff:
</font><font size=1 face="sans-serif">[oXygen-user]
Displaying empty elements (or not)</font>
<br><font size=1 color=#5f5f5f face="sans-serif">Gesendet von:
</font><font size=1 face="sans-serif">oxygen-user-bounces@oxygenxml.com</font>
<br>
<hr noshade>
<br>
<br>
<br><tt><font size=2>Hi folks,<br>
<br>
oXygen supports the CSS3 selector :empty, so (for example) we can hide<br>
an element that has no content styled, in the Author View, for<br>
"preview", while showing it in an editing style.<br>
<br>
This is useful when, for example, editing documents whose schemas<br>
require elements in places where the user has no content for them. So<br>
if we have<br>
<br>
<sect><head/><p>Headless section</p></sect><br>
<br>
we don't have to see anything where the empty 'head' element is, at<br>
least when oXygen Author is set to "No Tags".<br>
<br>
Unfortunately, however, since CSS isn't XPath, there's no way to<br>
suppress the 'sect' element, when we have<br>
<br>
<sect><head/></sect><br>
<br>
(We can make the 'head' disappear but then we see a placeholder for the
'sect'.)<br>
<br>
I know the correct solution is not to deploy schemas that require<br>
elements that are not always used. But I wonder if anyone has a CSS<br>
workaround or an oXygen extension to suggest so that my oXygen XML<br>
Author preview can show something more like what the document will<br>
look like when it is formatted and the offending elements are dropped.<br>
<br>
Any ideas?<br>
<br>
Thanks, Wendell<br>
<br>
Wendell Piez | </font></tt><a href=http://www.wendellpiez.com/><tt><font size=2>http://www.wendellpiez.com</font></tt></a><tt><font size=2><br>
XML | XSLT | electronic publishing<br>
Eat Your Vegetables<br>
_____oo_________o_o___ooooo____ooooooo_^<br>
_______________________________________________<br>
oXygen-user mailing list<br>
oXygen-user@oxygenxml.com<br>
</font></tt><a href="http://www.oxygenxml.com/mailman/listinfo/oxygen-user"><tt><font size=2>http://www.oxygenxml.com/mailman/listinfo/oxygen-user</font></tt></a><tt><font size=2><br>
</font></tt>
<br><p></p><p><strong>GDV Dienstleistungs-GmbH & Co. KG</strong><br><span style="line-height: 1.22;">Glockengießerwall 1<br></span><span style="line-height: 1.22;">D-20095 Hamburg<br></span><span style="line-height: 1.22;">www.gdv-dl.de</span></p><p><span style="line-height: 1.22;">Sitz und Registergericht: Hamburg<br></span><span style="line-height: 1.22;">HRA 93 894<br></span><span style="line-height: 1.22;">USt.-IdNr : DE 205183123</span></p><p><span style="line-height: 1.22;">Komplementärin:<br></span><span style="line-height: 1.22;">GDV Beteiligungsgesellschaft mbH<br></span><span style="line-height: 1.22;">Sitz und Registergericht: Hamburg<br></span><span style="line-height: 1.22;">HRB 71 153</span></p><p><span style="line-height: 1.22;">Geschäftsführer:<br></span><span style="line-height: 1.22;">Volker Sonnenburg<br></span><span style="line-height: 1.22;">Heiko Beermann</span></p><p><span style="line-height: 1.22;">------------------------------------------------------------------<br></span><span style="line-height: 1.22;">Diese E-Mail und alle Anhänge enthalten vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe der E-Mail ist nicht gestattet.</span></p><p><span style="line-height: 1.22;">This e-mail and any attached files may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorised copying, disclosure or distributionof the material in this e-mail is strictly forbidden.</span></p><p></p>