Structure vs Semantics (was: RE: XHTML 2.0: Suggestion for <addr/ > and <blockaddr/> to replace <address/>)

Lachlan Hunt wrote:
> karl@w3.org wrote:
 
> > ...the usual confusion is between
> > - Semantics
> > - Structure
> > - Presentation

> > Structure and Presentation are very difficult to distinguish and it 
> > seems sometimes overkilling to have two tags for the same semantics 
> > when only the structure has changed.
 
> Yes, I agree, but, unfortunately, it's necessary to 
> maintain structure.

Why?

This has bothered me for a while, but I couldn't put my
finger on it until your message.

Semantics is important for any automated processing,
including a reasonable default display.

Structure is important to the extent that it helps 
with semantics.  Nesting is important.  Order is
sometimes important. 

But why is block vs inline important?  

--------------------------

Possibility 1: 

The conceptual "size" of the contained information 
is truly important.  

Some element types (such as <strong>) are large 
enough to contain subelements, but not large 
enough to stand on their own.  Since they can't 
stand on their own, they shouldn't contain 
anything that does - or even could.

If we go with this explanation, then href
should probably be limited to these "small"
or "inline" elements.  (This doesn't quite 
solve the nested links issue, but it makes
the problem tractable.)

Possibility 2:

There is no meaningful non-presentational
difference, and we should get rid of the
distinction.   (We should perhaps still
define a sensible default style).

This would get rid of several junk distinctions,
such as div/span or element/blockelement.

-----------------

Note that the original question about address
is something of a red herring.  People still
understand a postal address written on a
single line; the reason we feel strongly that 
it should be a "block" is that it contains
subelements like "street address" and "city"
that we need to separate for a contacts
database.  So long as we're using plain 
text contents (instead of attributes or
subelements), this cannot be done 
correctly, and there isn't much point in
sweating over how close we come.  

If we want to get it right, then we should
define an "address" module, with elements
something like:

<address>
	<streetaddress>
		<boxnumber>123</boxnumber>
		<street>example way</street>
		<building>Impressive Hall</building>
	</streetaddress>
	<city>Sample Town<city>
	<state hmm="or region?">Ontario</state>
	<country>Canada</country>
	<postcode>2x4 C2C</postcode>
</address>

(I suggest a separate module because getting it 
right requires enough care and detail that it 
should really stand on its own.)

-jJ

Received on Monday, 8 December 2003 10:49:26 UTC