W3C home > Mailing lists > Public > www-svg@w3.org > September 2005

Re: Set circle radius using CSS

From: Philippe Lhoste <PhiLho@GMX.net>
Date: Sat, 17 Sep 2005 09:41:22 +0200
Message-ID: <432BC8A2.80500@GMX.net>
To: David Woolley <david@djwhome.demon.co.uk>
CC: www-svg@w3.org

David Woolley wrote:
>> Moreover, I would personally discourage you from using CSS with SVG at all,
>> if you can help it. CSS is not required for an implementation, it's not used
> 
> My impression is that CSS support was originally proposed as part of the
> token compliance to W3C accessibility requirements; it allows the user
> some ability to make pages more easily readable when they have colour and
> other visiou defects, but currently there doesn't seem any serious 
> interest in accessibilty.

This is a sensible explaination, although in a visual medium where text 
position and size is important (and hard to alter in SVG 1.1), using a 
different stylesheet to make, eg., text bigger would be problematic, 
with text overwritting other text, masking elements or going behind 
elements, etc.

The problem is that CSS has been abused, we often see:

<circle cx="50" cy="50" r="20"
     style="fill: lightblue; stroke: blue; stroke-width: 5;"/>

instead of:

<circle cx="50" cy="50" r="20"
     fill="lightblue" stroke="blue" stroke-width="5"/>

for no particular reason...

OTOH, CSS can be useful to define real styles with classes, ie. 
properties that can be applied to a great number of objects: this is a 
good shortcut, reducing size of SVG file, allowing to change the 
properties of a great number of similar objects at once.

Of course, this can be done without CSS too (except for cascading? which 
isn't used so much in SVG) using entities.

-- 
Philippe Lhoste
--  (near) Paris -- France
--  http://Phi.Lho.free.fr
--  --  --  --  --  --  --  --  --  --  --  --  --  --
Received on Saturday, 17 September 2005 07:41:58 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:31 GMT