[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Hyphens vs underscores in element names

  • From: Warren Hedley <w.hedley@a...>
  • To: xml-dev@i...
  • Date: Wed, 26 Jan 2000 18:26:22 +1300

page names hyphens versus underscores
Hello XML-DEV

One of the more popular arguments between the development team for
FieldML regards a convention for the naming of elements and
attributes in our ML collection. The debate focuses over whether
we should use underscores (num_elements), hyphens (num-elements),
capitalisation (numElements) or runtogether (numelements). We've
eliminated capitalisation and runtogether because they don't
look as nice, and are now reduced to hyphens vs. underscores. The
older part of the development team is familiar with Fortran and C
and are keen to use underscores. However I've noticed in a brief
survey (results below) that most of the W3C-endorsed stuff seems
to feature minus signs.

Can anyone suggest any compelling reasons for going either way?
Does anyone want to add more data to my survey?

The Fortran coders also argued that there might be confusion with
arithmetic minus signs, if an application was to display something
like "mesh-1 - element-1", where "mesh-1" and "element-1" are
identifying attributes of type NMTOKEN (would have used ID but we
don't require uniqueness within a file). However since I cannot
prevent someone from using hyphens in an attribute value (without
resorting to schema validation), I don't think this holds. The
argument continued that users would be encouraged to use underscores
in identifiers if the element names also used underscores.

Begin Survey Results
====================

Hyphens (last 2 not XML applications, but W3C) :

XSLT = <for-each>, <call-template>, etc.
XPath & XPointer = ancestor-or-self, etc
SMIL = <root-layout> @skip-content
W3C spec names = REC-DOM-Level-1-19981001
XHTML module names = xhtml11-tableb-1.mod

Underscores :

BioML = <dna_type> <keep_space> (not W3C)

Runtogether (I suspect this was chosen for legacy reasons ??) :

MathML = <maligngroup>
XHTML = <textarea> @colspan

Capitalisation (not all W3C WDs or Notes) :

XML-Schema = <unparsedEntity> @schemaName
SVG (Scalable Vector Graphics) = <animateMotion>
CDF (Channel Description Format) = <PublicationDate>
TEI (Text Encoding Initiative) = <docImprint>
OCS (Open Content Syndication) = <updatePeriod>

End Survey Results
==================

In case anyone is interested, FieldML is a language for marking up
spatially and time varying fields, targeted at finite element
packages (in particular some software developed at Auckland called
CMISS). The development of FieldML can be followed here

http://www.esc.auckland.ac.nz/sites/physiome/fieldml/pages/

-- 
Warren Hedley
Department of Engineering Science
Auckland University
New Zealand

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i...
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ or CD-ROM/ISBN 981-02-3594-1
Unsubscribe by posting to majordom@i... the message
unsubscribe xml-dev  (or)
unsubscribe xml-dev your-subscribed-email@your-subscribed-address

Please note: New list subscriptions now closed in preparation for transfer to OASIS.



PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.