ZUL formatting problem
Is it a valid XML format?
Zul Editor requires a strict XML file for input, and there's no end tag for each of four <n:span> in your case.
zul is registered as a kind of XML file and what you proceed is done by Eclipse formatter, not ZK Studio.
@iantsai: Sorry, it was a mistake. There should be proper end tags in my example.
@henrichen: May ZK Studio change these rules? Maybe Ant pluging do it ...
Well, ZK Studio only handles part inside <zscript> tag. We would not change Eclipse's behavior since it is too risky. Maybe you want to check if there was any way to "configure" the Eclipse formatter.
Wow, I have found this in the spec http://www.w3.org/TR/2004/REC-xml-20040204/#sec-white-space and Eclipse (3.5, WTP) can handle it, so
<window xml:space="preserve"> <n:span>A</n:span><n:span>B</n:span> </window>
Does not change the format even if I run (Source->Format Ctrl+Shift+F).
Always learning ...
BTW. Generally, it should be possible to switch on/off in the XSD, see http://www.w3.org/TR/xmlschema-1/#cAttributeUse but I do not know how Eclipse handle it. I have tried to edit zul.xsd in the org.zkoss.eclipse.editor_0.9.6.v200912041237.jar, but the formatting was still generating new lines.
ZK - Open Source Ajax Java Framework
Hi,
when i have two elements in ZUL like:
then the automatic Eclipse formatting (Source->Format Ctrl+Shift+F) changes them to:
<n:span>A<n:span> <n:span>B<n:span>which makes a different result in the HTML: "AB" vs. "A B". Is there any way how to fix this?
Thanks