- From: Brad Kemper <brkemper@comcast.net>
- Date: Thu, 17 Jul 2008 21:28:11 -0700
- To: fantasai <fantasai.lists@inkedblade.net>
- Cc: Mike Wilson <mikewse@hotmail.com>, 'www-style list' <www-style@w3.org>
On Jul 17, 2008, at 12:43 PM, fantasai wrote: > Mike Wilson wrote: >> It's great that you are working with this! >> The "define" suggestion looks nice. A slight variation that I also >> think is nice, is blending in some of the ideas from your original >> proposal which would result in: >> @define { >> myForegroundColor: blue; >> myBackgroundColor: green; >> myButtonStyle: { >> border: outset silver; >> background: silver; >> } >> } >> (It probably has to be adjusted somewhat to play well with the >> CSS parser, but you get the general idea.) >> I agree with Brad and others that the media stuff could instead >> be done with normal media blocks. >> Lastly, I'd put my vote on fantasai's "$ dereferencing" or >> something similar and well known. > > I think my personal take would be to use =var=. I liked Brad's > suggestion of using =, but =var seems a bit unbalanced to me. > > h1 { > =myHeaderStyle=; > background-color: =myBackgroundColor=; > } > > Not sure what other people think. :) It's not a well-known syntax, > but you can use it for both kinds of dereferencing. > > ~fantasai That's interesting. The thing I like about the equals sign on the left is that it points to the thing it is being assigned to. So for instance, if you ignored the CSS notation (and had the equal sign only on the left), you would have something like this: h1=myHeaderStyle background-color=myBackgroundColor ...which makes sense to me because you are assigning myHeaderStyle to the h1, and myBackgroundColor to the background-color. As a Web author, I am familiar with such assignments within JavaScript (and VBScript). I do not understand the argument others have made that a dollar sign would be more natural. To me it is just another abstract symbol without anything to make it more understandable as a variable identifier. Is it because in some programming languages it is used to denote string-type variables?
Received on Friday, 18 July 2008 04:28:56 UTC