|
Posted by Eric Bohlman on 07/14/06 22:00
Spartanicus <invalid@invalid.invalid> wrote in
news:2f8fb2p75b5ejrst9jojnmmhcjii0q2okk@4ax.com:
> TreatmentPlant <treatmentplant@DIESPAMMERS.iinet.net.au> wrote:
>
>>colour1:=red;
>>colour2:=blue;
>>colour3:=white;
>>
>>body {background-color:colour3; color:colour2; border: thin solid
>>colour1} h1 {background-color:colour2; color:colour3;}
>>h2 {background-color:colour3; color:colour1;}
>>etc
>>
>>...you could change the entire site colour scheme more easily.
>>...it would save you minutes!
>
> Any decent editor has a S&R feature
>
> Search: color:blue
> Replace: color:red
>
> Only takes a few seconds
This would break down if he started with:
colour1:=red;
colour2:=red;
colour3:=white;
and he wanted to change it to his example. "Replace all" would change
his body border and h2 foreground to blue as well. Inspect/confirm S&R
would certainly save keystrokes, but it would have increased cognitive
load (have to determine, for every "red" you find, whether it was one of
the ones you wanted to change).
It's really the old issue of separating the *name* of something from its
*value*. We all, hopefully, know that CSS class names should reflect the
*purpose* of the class rather than its *appearance*, not just because it
lets us easily change them, but also because we might start out with two
or more areas with different purposes but the same appearance, and later
want them to have different appearances.
However, what the OP wants could easily be achieved by using any old text
preprocessor like m4.
Navigation:
[Reply to this message]
|