[OpenLayers-Dev] #736 (external graphic as style for vector points)

Andreas Hocevar andreas.hocevar at gmail.com
Tue Jun 5 09:07:56 EDT 2007


Hi,

> On 6/5/07, Christopher Schmidt <crschmidt at metacarta.com> wrote:
> > > As in the SLD specification, only a size for the bitmap can be
> > > specified. So external graphics will always be rendered with same
> > > width and height. For width and height, the existing pointRadius
> > > property is used.

As it turned out, SVG keeps the aspect ratio of images when width and
height are the same. It takes the height then, and adjusts the width
to keep the aspect ratio. Pat says this is the way the SLD
specification says.

The problem is with VML. The v:image element stretches the image to
the specified width and height. It should be possible to use image
fills on a rect element, specifying an "aspect" attribute. But this
did not work for me. If anyone knows how to do this, please speak up!

In the meantime, I added a graphicWidth and graphicHeight style
property to specify width and height separately. This is now in the
sandbox.

Regards,
Andreas.



More information about the Dev mailing list