W3C home > Mailing lists > Public > www-svg@w3.org > October 1999

Re: Cross hatch fills support in svg

From: Jan Aarsaether <jaa@metis.no>
Date: 14 Oct 1999 15:23:04 +0200
To: www-svg@w3.org
Message-ID: <uso3e6pqf.fsf@cenote.oslo.metis.no>

Chris Lilley wrote:
> Jan Aarsaether wrote:
> > 
> > I've been looking for a convenient way of specifying cross hatch
> > patters on drawing primitive. While there is nice support for fill
> > opacity and color, there seems to be little direct support for
> > specifying something so commonly used as such patterns.
> 
> You have a correct example of how to do this in your example below
> 
> > The only way I see achieving this is would be something like this:
> > 
> >  <defs>
> >   <pattern id="pattern2" x="0" y="0" width="30" height="30">
> >    <path style="stroke:black" d="_whatevernecessary_"/>
> >   </pattern>
> >  </defs>
> >  <g>
> >   <rect x="0" y="0" width="832" height="896" style="fill:url(#pattern2);"/>
> >  </g>

This might be somewhat off topic, but I'm having trouble visualizing
custom patterns (like above) using CSIRO svg viewer r0.71. Is this a
know problem with this viewer or has somebody managed to do this?

> > But it seems weird that such common functionality is not supported in
> > a more direct manner in svg. Please, tell me it is!!!!! 
> 
> Which fill patterns would you like? Would they be universally suitable,
> or would other people want different ones? Looking at a specification
> such as CGM, many of the post-standardisation registered extensions are
> for slight variations on fill pattermns, some of which have defined
> meanings in particular countries or particular vertical markets. Then
> there is a problem of which implementations support which registered
> extrensions.
> 
> So, we could either supply a small set which would not please the users,
> or a large set which would not please the implementors and still not
> please the users, or allow a distributed, decentralised, fully general
> pattern facility. Which is why SVG was designed that way.

I understand the power of the current implementation, but was
surprised not to find a small set from which I could hopefully find
something close to what I really needed. I guess it really depends on
the application. Our symbols are more representative of nature than
accurate depictions of real objects. Because of this is the kind of
pattern on a primitive often of less importance than it having a
pattern or not.

> So if your particular application uses 50 particular patterns, you can
> make an SVG file with those 50 patterns and put it on your web site and
> anyone who wants to (for example, users of software that you write, etc)
> can use those patterns. And you will know that any conforming SVG
> vioewer will display them fine, even ones written before you came up
> with your desired hatch patterns.

This is a good idea which I'll look into. Thanks for the response!

--jaa
Received on Thursday, 14 October 1999 09:26:54 GMT

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