Horizontal rules

10.
Horizontal rules is an area that is badly in need of attention.

There are many possible implementation options:
1. as a border round white space - the option used by Mozilla and Explorer
2. as a border-top
3. as a border-left and border-top - the option used by Opera

Now if one takes 1, one needs to know what (the deprecated) noshade
attribute's equivalent is. 

It seems that it does not have a CSS equivalent using option 1 since its
effect in HTML is to fill in the middle - that is to give it a background.
This means that HR cannot be implemented in this way (since if one wishes
to specify that one's horizontal rules should not be shaded with CSS, then
one must specify background-color, but if one does not wish to set the HR
border-color (i.e., if one wishes to leave this to one's users), it is
impossible to set background-color, and so therfore one cannot suppress
the shading).

Another reason why horizontal rules cannot be implemented in this way is
because in Mozilla/Explorer <HR size=1> sets the border to a single thin
line, but if HR {height: 1px}, the result is a line round white space, so
size and height are not equivalent, thereby breaking the size attribute
deprecation - to get <HR size=1> using this implementation, you would need
HR {height: 0}.

Similar reasoning shows that Opera's approach is also wrong.

Having shown that these implementations is wrong, I would suggest that HR
{border-top: <width> groove} is the best possible implementation. This
then makes <HR size=whatever> meaningful as setting the border width and
noshade meaningful as setting the border-style to solid. It also means,
somewhat anomalously, that the HR[color] property sets the border colour
of HR and that color has no effect on HR if the UA has chosen to give HR a
border colour.

Note that the option in the sample style sheet for CSS is a non-starter
since HR {border: 1px inset} is not the groove suggested by HTML, and
since the width is 1px, the 3d effects can have no effect - better is HR
{border-top: 2px groove}.


=====
----------------------------------------------------------
From Matthew Brealey (http://members.tripod.co.uk/lawnet (for law)or http://members.tripod.co.uk/lawnet/WEBFRAME.HTM (for CSS))
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

Received on Friday, 28 January 2000 07:29:57 UTC