W3C home > Mailing lists > Public > www-style@w3.org > January 2005

Re: [CSS3] UI element states pseudo-classes

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Sun, 9 Jan 2005 15:57:52 -0800
Message-ID: <003501c4f6a7$07bdb120$0c01a8c0@TERRA>
To: "Paul Norman" <penorman@mac.com>, <www-style@w3.org>

| What you suggest will only select an element if it is selected by
| default.

Slightly out of scope. Static attributes versus dynamic.

Lets take a look on the problem from the different point of view.
Example from real life:

I have a customer who asked to implement input elements which reflect
their runtime states to the values of attributes. Thus if checkbox was 
checked by user it has attribute "checked"
if it does not checked it has not such attribute despite of its intital 
state.

The reason is simple - user changed the form and whould like to save (copy, 
paste) it in *its current state* with actual values.
Other use case: e-mail message with input form. They want to be able to send 
some e.g. questionary (as a form) to recipient and receive
answers back in the same form.

Personally I think these requirements are reasonable and practice shows 
highly useful.

Anyway there is no logical or physical conflicts nor specification which 
prohibit such runtime modifiction of
attributes in the DOM. So CSS styling of input elements theoretically (and 
practicaly) could be made "naturally" - without need of
:checked, :disabled and e.g. mysterious :repeat-item

BTW:
Why :repeat-item, :choices, :values, :read-write, etc. are declared in CSS 
and not solely in XHTML/XForms where it belongs?
And what about adding other states from e.g. SVG/interactive into CSS then?

Am I alone who thinks that attempt to enumerate all possible UI states from 
all possible UI elements in CSS is an overkill?

Andrew Fedoniouk.
http://terrainfotmatica.com



Original Message from: "Paul Norman" <penorman@mac.com>
|
|
| On 9-Jan-05, at 3:12 AM, Andrew Fedoniouk wrote:
|
| >
| >
| > | It doesn't, actually.  Apart from the issue Laurens pointed out,
| > :checked
| > | applies to <option> elements in HTML, say....
| >
| > Why not
| > option[selected]?
| > why selected state needs to be named as ":checked"?
|
| What you suggest will only select an element if it is selected by
| default.
| I'll use the case of checkboxes since I find them easier to talk about.
| If you have some checkbox that isn't checked by default and it hasn't
| been checked
| neither selector matches it. If a user then checks it :checked will
| match it
| but what you suggest using won't.
|
| 
Received on Sunday, 9 January 2005 23:57:58 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:35 GMT