W3C home > Mailing lists > Public > www-style@w3.org > June 2003

RE: Font definition

From: Matthew Fletcher <fletcherm@business1st.uk.com>
Date: Mon, 2 Jun 2003 09:04:22 +0100
Message-ID: <ACD217E6A92DA84FABE46143198468B6228164@srv3.Office.B-1St.Com>
To: <www-style@w3.org>

Yes, sorry guys, I realised that constant would be a more appropriate term as soon as I sent the original message.

Matt Fletcher

-----Original Message-----
From: Ben Godfrey [mailto:afternoon@uk2.net]
Sent: 29 May 2003 20:51
To: www-style@w3.org
Subject: Re: Font definition




Definitely.

There would be no need to change the values, so variable is just a bad 
choice of word on my part.

Ben


On Thursday, May 29, 2003, at 19:10 Europe/London, Matt wrote:

>
> Ben Godfrey wrote:
>>> What about every other value? Wouldn't it be great to be able to
>>> declare "variables" at the top of a stylesheet and reference them
>>> where needed. Color schemes are the example that spring to mind.
>>
>> This would be a powerful way to modularise complicated stylesheets.
>> One could set variables and import a set of styles to make use of
>> those variables, similar to the way that XSL is sometimes
>> modularised.
>>
>> This can be done at the moment with the approach of assigning
>> selectors to properties rather than vice versa mentioned
>> previously, but providing variables would increase the separation
>> and maintainability of the individual files. This could be very
>> useful in environments with large disparate sites and teams.
>
> Wouldn't it be better to use contants instead of variables? Perhaps an
> @-rule:
>
> @constants {
>  %mycolour%: #ffc;
>  %myothercolor%: #cce;
>  %mylength: 2em;
> }
>
> p {
>  color: %mycolor%;
>  margin-top: %my-length%;
> }
> etc.
>
> Matt
>
>

(q)	Ben Godfrey?
(a)	Web Developer and Designer
	See http://aftnn.org/ for details
Received on Monday, 2 June 2003 04:05:51 GMT

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