[CSS21][css3-ui] defining 'cursor: auto' properly

The 'auto' value of the 'cursor' property currently has, in both:
[1] http://www.w3.org/TR/2011/REC-CSS2-20110607/ui.html#propdef-cursor
[2] http://dev.w3.org/csswg/css3-ui/#cursor
the definition:
  # auto
  #   The UA determines the cursor to display based on the current context.
which is nowhere near clear enough to lead to interoperability.

This has been previously discussed in:
[3] http://lists.w3.org/Archives/Public/www-style/2000Jan/thread.html#msg21
[4] https://lists.w3.org/Archives/Member/w3c-css-wg/2001JulSep/0388.html (attached, since I was the sole author and can thus change its confidentiality level)
[5] https://lists.w3.org/Archives/Member/w3c-css-wg/2001OctDec/0014.html (teleconference minutes 2001-10-08, member confidential)
[6] https://lists.w3.org/Archives/Member/w3c-css-wg/2002JulSep/0021.html (my comments on a member-confidential draft of css3-ui, largely restating the above)
[7] https://lists.w3.org/Archives/Member/w3c-css-wg/2002JulSep/0289.html (Ian Hickson's Last Call comments on CSS 2.1, again largely just restating the above)

The basic problem is that there are two basic interpretations of the
spec (with various options in between):

  (1) All UA default behavior for the 'cursor' property must be
  encoded in the 'auto' value; using the 'cursor' property in the UA
  style sheet is forbidden.

  (2) The need for an 'auto' value exists only because there are
  some elements that should have a 'text' or 'vertical-text' cursor
  for part of the element and the 'default' cursor for other parts
  of the element.  The 'auto' value exists only to cover this case,
  and all other UA default behavior should be described in the UA
  style sheet as for the rest of CSS.

I strongly prefer option (2), since it is more in line with the way
the rest of CSS works in terms of cascading.  Gecko implements
option (2).

Ian Hickson's proposal for option (2) quoting from [7] above is:
  # auto
  #   Same as 'text' when the cursor is over text, otherwise 'default'.

Adjusting this for the possibility of vertical text yields:
  # auto
  #   Same as 'text' or 'vertical-text' when the cursor is over text
  #   (depending on the glyph orientation), otherwise 'default'.

(I'd like this text to be more precise; I think glyph orientation is
the correct term based on
http://dev.w3.org/csswg/css3-writing-modes/#text-flow and
http://fantasai.inkedblade.net/style/discuss/vertical-text/paper ,
but I can't find any terms for the possible values glyph orientation
can have.)

I propose that we adopt the first of these definitions as errata to
CSS 2.1 and the second (possibly revised with better terminology and
references) for css3-ui.

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                           http://www.mozilla.org/   𝄂

Forwarded message 1

I've always been a bit puzzled by 'cursor: auto'.  I think there are at
least two possible ways to interpret the definition in CSS2, which is
"The UA determines the cursor to display based on the current context.":

 * Since all default values of the 'cursor' property must be obtained
   when using 'cursor: auto', the UA stylesheet *must* specify 'cursor:
   auto' for all elements, and all the default values must be written in
   code rather than CSS.  This seems to defeat the point of a UA
   stylesheet, which is where the 'cursor' property is most useful.

 * The 'auto' value for the 'cursor' property exists to allow automatic
   switching between the 'text' and 'default' cursors within a given
   element -- for example, within a P element the cursor should be the
   'text' cursor when the pointer is over text and the 'default' cursor
   otherwise.

Is one of these correct, or is it something else?  (I strongly prefer
the second, although I had previously thought it was the first.)

-David

-- 
L. David Baron        <URL: http://www.people.fas.harvard.edu/~dbaron/ >
Mozilla Contributor                      <URL: http://www.mozilla.org/ >
Invited Expert, W3C CSS WG          <URL: http://www.w3.org/Style/CSS/ >

Received on Monday, 21 January 2013 11:53:39 UTC