- From: Jelks Cabaniss <jelks@jelks.nu>
- Date: Sat, 2 Jan 1999 18:09:00 -0500
- To: <www-style@w3.org>
> > concept be expanded to handle something like: > > > > @define myTheme = "color: navy; background: #eee; ...} > > h3 { myTheme; font-size: 1.1em } > > p.standout { myTheme; font-size: .8em } > > I guess it could, or even: > > @define myTheme(x,y) = "color: $x; background: $y;" Making CSS a programming language raises the hair on the back of my neck. > My preference is make CSS powerful in its stylistic capabilities, but > simple in its language. Separate tools for separate tasks: people that > would know how to use macros like those above are probably also > knowledgeable enough to apply external tools, such as cpp, m4, editor > macros, databases, server-side includes or scripts/programs of their > own making to maintain complex style sheets. The suggestion (#28, "Symbolic Constants") is rather vague. I find the example given, @define orange = #faa; of dubious value: it just defines a *value* in a declaration. What good does that really do, anyway? Chris pointed out that the proposal is to provide a maintainability convenience. Many of us are repeatedly declaring the same set of styles over and over. You *could* use grouping, followed by overriding/extending, h1, h2, h3 { styles common to h1, h2, h3 } h1 { overrides/extends common styles } h1 { overrides/extends common styles } h1 { overrides/extends common styles } but it's a pain, and inefficient to boot, especially if you're overriding parts of styles already declared. I "voted" in favor of #28, but please discount it if the purpose is just to declare single *values* -- I don't see the value :). If OTOH it is to define one or more *declarations*, I think it will be useful to many of us who hand-code our CSS and don't use or have access to server-side magic. /Jelks
Received on Saturday, 2 January 1999 18:09:23 UTC