<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 11/3/2015 1:57 PM, Andreas Plesch
wrote:<br>
:<br>
:<br>
<br>
</div>
<blockquote
cite="mid:CAKdk67uM2bGun=RYri_grPK9rKCMqAr2WGPqpNjsya+VyB34_A@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div>
<div><br>
<div>The use case for me is that it required quite a bit
of repetitive effort to get x3d output generated by the
<a moz-do-not-send="true" href="http://vrmath2.net"
target="_blank">vrmath2.net</a> editor such as<br>
<br>
<a moz-do-not-send="true"
href="https://vrmath2.net/embed/?url=/sites/default/files/user/u342/x3d/helical_gears_smooth_opt.x3d"
target="_blank">https://vrmath2.net/embed/?url=/sites/default/files/user/u342/x3d/helical_gears_smooth_opt.x3d</a><br>
<br>
</div>
into a conforming format so that use of x3d-edit and xj3d
would start to make more sense. A lot of that effort was
just to get the case correct. Most of the remaining effort
was to get rid of the nonconforming attributes such as id.
(Perhaps there is way to keep nonconforming attributes
around as comments). <br>
</div>
</div>
</div>
</div>
</blockquote>
<br>
I thought that 'id' was acceptable because it is needed so much in
XML and especially HTML. If it is not, it will need to be in X3D V4.<br>
<br>
<br>
<blockquote
cite="mid:CAKdk67uM2bGun=RYri_grPK9rKCMqAr2WGPqpNjsya+VyB34_A@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>Since html5 is (in general?) not case sensitive, </div>
</div>
</blockquote>
<br>
HTML5 tags and attribute names are case insensitive. I posted the
W3C reference in a previous email (last paragraph of
<a class="moz-txt-link-freetext" href="http://www.w3.org/TR/html5/syntax.html#writing">http://www.w3.org/TR/html5/syntax.html#writing</a>)<br>
<br>
<br>
<blockquote
cite="mid:CAKdk67uM2bGun=RYri_grPK9rKCMqAr2WGPqpNjsya+VyB34_A@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>prose on x3d vocabulary within a html5 context would
presumably be about what the recommended, case-sensitive form
is for reasons of validation, compatibility with xml and other
contexts, and general readability versus what the presumably
accepted but discouraged case-insensitive form is. Or is it
something else it should address ?<br>
</div>
</div>
</blockquote>
<br>
<br>
X3D in HTML5 needs to be case insensitive to follow the rules and
conventions for that. <br>
<br>
Also need to identify tags with children that need to be closed
(e.g., <transform>...</transform>)<br>
Tags that sometimes don't have children - these can be self-closing
(e.g. <transform USE='OtherTransform' /><br>
Tags that are void (no closing indicator). HTML examples are
<br>, <img>, etc.<br>
See <a class="moz-txt-link-freetext" href="http://www.w3.org/TR/html5/syntax.html#start-tags">http://www.w3.org/TR/html5/syntax.html#start-tags</a> for details<br>
<br>
<br>
Leonard Daly<br>
<br>
<br>
<br>
<br>
<blockquote
cite="mid:CAKdk67uM2bGun=RYri_grPK9rKCMqAr2WGPqpNjsya+VyB34_A@mail.gmail.com"
type="cite">
<div dir="ltr">
<div><br>
</div>
Andreas<br>
<div><br>
<br>
<div>
<div><br>
<div><br>
</div>
</div>
</div>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Tue, Nov 3, 2015 at 2:10 PM, Don
Brutzman <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:brutzman@nps.edu" target="_blank">brutzman@nps.edu</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">Thanks for
the good thinking.<br>
<br>
Some time ago, when first looking at HTML lower-case
elements and X3DOM integration, there was good dialog on the
mail lists. No doubt available in the archives.<br>
<br>
It would appear that both forms (CamelCase and
lowercase/miXedcAsE) are desirable for X3D authors depending
on their html publication context.<br>
<br>
At that stage I created a stylesheet that creates a table
for producing lower-case version of X3D element names and
attributes. It walks the X3D schema in a manner similar to
what you are suggesting.<br>
<br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/</a><br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dElementsLowerCaseTable.html"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dElementsLowerCaseTable.html</a><br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dAttributesLowerCaseTable.html"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dAttributesLowerCaseTable.html</a><br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dElementsAttributesLowerCaseTable.txt"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dElementsAttributesLowerCaseTable.txt</a><br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dElementsAttributesLowerCaseTableConstruction.xslt"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dElementsAttributesLowerCaseTableConstruction.xslt</a><br>
<br>
Just tuned them up a little. Might need more precise
filtering to avoid duplicates, etc.<br>
<br>
Hopefully this is useful.<br>
<br>
As you point out, the X3D Tidy stylesheet looks at this task
too.<br>
<br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dTidy.html"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dTidy.html</a><br>
<a moz-do-not-send="true"
href="http://www.web3d.org/x3d/stylesheets/X3dTidy.xslt"
rel="noreferrer" target="_blank">http://www.web3d.org/x3d/stylesheets/X3dTidy.xslt</a><br>
<br>
At this point, it might be good to articulate any use cases
and the relevant HTML5 prose on case sensitivity.<br>
<br>
Open source. All suggestions, improvements or additions
welcome.<br>
<br>
<br>
On 11/3/2015 9:34 AM, Andreas Plesch wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
Since the idea of having a x3d document which is
conforming as much as possible is attractive, I am
thinking of a tool which corrects element names and
attribute names to their correct case sensitive spelling.
Is there such a tool ?<br>
<br>
In principle I think it could work by:<br>
1) extract all element and attribute names from the .dtd
and/or schema<br>
2) go through all elements (recursively) in
(nonconforming) x3d document<br>
2a) normalize element name to lower-case and see if there
is a corresponding normalized node name in dtd<br>
2b) if there is replace with correct, case sensitive
element name<br>
if not flag as unknown (or ignore, optionally
eliminate)<br>
2c) do the same for all used attribute names<br>
<br>
This would work for most if not all names since they can
all (most?) be distinguished in a case insensitive manner.<br>
<br>
The tool of choice would be a xsl style sheet which may
have to be generated by another stylesheet which processes
the .dtd/schema. What would be other strategies (going
through json) ? How would one go about this in more detail
? Perhaps the x3d-tidy.xsl style sheet is a starting point
? It looks daunting.<br>
<br>
However, I would probably start much more
straightforwardly by looking at<br>
<a moz-do-not-send="true"
href="http://www.web3d.org/specifications/X3dDoctypeDocumentation3.3.html"
rel="noreferrer" target="_blank">http://www.web3d.org/specifications/X3dDoctypeDocumentation3.3.html</a>
and<br>
<a moz-do-not-send="true"
href="http://www.web3d.org/specifications/X3dSchemaDocumentation3.3/x3d-3.3.html"
rel="noreferrer" target="_blank">http://www.web3d.org/specifications/X3dSchemaDocumentation3.3/x3d-3.3.html</a><br>
to assemble a list and then use unix tools such as sed/awk
and such<br>
to transform the x3d. What is used to generate the above
documentation from the .dtd/xsd ?<br>
<br>
Any input much appreciated,<br>
<br>
Andreas<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
x3d-public mailing list<br>
<a moz-do-not-send="true"
href="mailto:x3d-public@web3d.org" target="_blank">x3d-public@web3d.org</a><br>
<a moz-do-not-send="true"
href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org"
rel="noreferrer" target="_blank">http://web3d.org/mailman/listinfo/x3d-public_web3d.org</a><br>
<br>
</blockquote>
<br>
<br>
all the best, Don<span class="HOEnZb"><font color="#888888"><br>
-- <br>
Don Brutzman Naval Postgraduate School, Code USW/Br
<a moz-do-not-send="true"
href="mailto:brutzman@nps.edu" target="_blank">brutzman@nps.edu</a><br>
Watkins 270, MOVES Institute, Monterey CA 93943-5000
USA <a moz-do-not-send="true"
href="tel:%2B1.831.656.2149" value="+18316562149"
target="_blank">+1.831.656.2149</a><br>
X3D graphics, virtual worlds, navy robotics <a
moz-do-not-send="true"
href="http://faculty.nps.edu/brutzman"
rel="noreferrer" target="_blank"><a class="moz-txt-link-freetext" href="http://faculty.nps.edu/brutzman">http://faculty.nps.edu/brutzman</a></a><br>
</font></span></blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
<div class="gmail_signature">Andreas Plesch<br>
39 Barbara Rd.<br>
Waltham, MA 02453</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
x3d-public mailing list
<a class="moz-txt-link-abbreviated" href="mailto:x3d-public@web3d.org">x3d-public@web3d.org</a>
<a class="moz-txt-link-freetext" href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org">http://web3d.org/mailman/listinfo/x3d-public_web3d.org</a>
</pre>
</blockquote>
<br>
<br>
<div class="moz-signature">-- <br>
<font class="tahoma,arial,helvetica san serif" color="#333366">
<font size="+1"><b>Leonard Daly</b></font><br>
X3D Co-Chair<br>
Cloud Consultant<br>
President, Daly Realism - <i>Creating the Future</i>
</font></div>
</body>
</html>