Re: [MapServer-users] Some remote SVG files doesn't in 8.1
Adding a width and height to the SVG also works, without having to remove the viewBox: http://www.w3.org/2000/svg"; width="10pt" height="10pt" viewBox="0 0 396.85 396.85"> Seth -- web:https://geographika.net & https://mapserverstudio.net twitter: @geographika On Wed, Jul 19, 2023, at 11:54 PM, Seth G wrote: > Hi Martin, > > The issue seems to be related to the viewBox property in the SVG file. > If you save the SVG source from > view-source:https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg > and remove the following text in a text editor the symbols display correctly: > > viewBox="0 0 396.85 396.85" > > Maybe it could be an upstream issue, or something has changed upstream that > breaks symbol size calculations. > > Seth > > > -- > web:https://geographika.net & https://mapserverstudio.net > twitter: @geographika > > On Tue, Jul 18, 2023, at 1:59 AM, Steve Lime wrote: >> There seems to be a regression with svg- I have another sample file that >> doesn’t render correctly (or at all). Just need to find a little time to >> resolve it. >> >> On Tue, Jul 11, 2023 at 12:10 PM Martin Høgh wrote: >>> I've a MapFile with a point layer using a class style with a SVG symbol: >>> >>> CLASS >>> NAME 'point' >>> STYLE >>> SYMBOL >>> 'https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg' >>> END >>> END >>> >>> In 7.6 this works fine, but in 8.1 the SVG symbol is not showing (no >>> errors but the image is blank). But if change the SVG file to e.g.: >>> >>> https://dev.w3.org/SVG/tools/svgweb/samples/svg-files/AJ_Digital_Camera.svg >>> >>> it works. So I guess it's something with the SVG file? >>> >>> MapServer version 8.0.1 PROJ version 7.2 GDAL version 3.4 OUTPUT=PNG >>> OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE >>> SUPPORTS=CAIRO SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV >>> SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT >>> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER >>> SUPPORTS=SOS_SERVER SUPPORTS=OGCAPI_SERVER SUPPORTS=FASTCGI >>> SUPPORTS=GEOS SUPPORTS=PBF INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL >>> INPUT=SHAPEFILE INPUT=FLATGEOBUF >>> >>> >>> ___ >>> MapServer-users mailing list >>> MapServer-users@lists.osgeo.org >>> https://lists.osgeo.org/mailman/listinfo/mapserver-users >> ___ >> MapServer-users mailing list >> MapServer-users@lists.osgeo.org >> https://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > ___ > MapServer-users mailing list > MapServer-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/mapserver-users > ___ MapServer-users mailing list MapServer-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [MapServer-users] Some remote SVG files doesn't in 8.1
Hi Martin, The issue seems to be related to the viewBox property in the SVG file. If you save the SVG source from view-source:https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg and remove the following text in a text editor the symbols display correctly: viewBox="0 0 396.85 396.85" Maybe it could be an upstream issue, or something has changed upstream that breaks symbol size calculations. Seth -- web:https://geographika.net & https://mapserverstudio.net twitter: @geographika On Tue, Jul 18, 2023, at 1:59 AM, Steve Lime wrote: > There seems to be a regression with svg- I have another sample file that > doesn’t render correctly (or at all). Just need to find a little time to > resolve it. > > On Tue, Jul 11, 2023 at 12:10 PM Martin Høgh wrote: >> I've a MapFile with a point layer using a class style with a SVG symbol: >> >> CLASS >> NAME 'point' >> STYLE >> SYMBOL >> 'https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg' >> END >> END >> >> In 7.6 this works fine, but in 8.1 the SVG symbol is not showing (no >> errors but the image is blank). But if change the SVG file to e.g.: >> >> https://dev.w3.org/SVG/tools/svgweb/samples/svg-files/AJ_Digital_Camera.svg >> >> it works. So I guess it's something with the SVG file? >> >> MapServer version 8.0.1 PROJ version 7.2 GDAL version 3.4 OUTPUT=PNG >> OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE >> SUPPORTS=CAIRO SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV >> SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT >> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER >> SUPPORTS=SOS_SERVER SUPPORTS=OGCAPI_SERVER SUPPORTS=FASTCGI >> SUPPORTS=GEOS SUPPORTS=PBF INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL >> INPUT=SHAPEFILE INPUT=FLATGEOBUF >> >> >> ___ >> MapServer-users mailing list >> MapServer-users@lists.osgeo.org >> https://lists.osgeo.org/mailman/listinfo/mapserver-users > ___ > MapServer-users mailing list > MapServer-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/mapserver-users > ___ MapServer-users mailing list MapServer-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [MapServer-users] Some remote SVG files doesn't in 8.1
There seems to be a regression with svg- I have another sample file that doesn’t render correctly (or at all). Just need to find a little time to resolve it. On Tue, Jul 11, 2023 at 12:10 PM Martin Høgh wrote: > I've a MapFile with a point layer using a class style with a SVG symbol: > > CLASS > NAME 'point' > STYLE > SYMBOL > ' > https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg > ' > END > END > > In 7.6 this works fine, but in 8.1 the SVG symbol is not showing (no > errors but the image is blank). But if change the SVG file to e.g.: > > https://dev.w3.org/SVG/tools/svgweb/samples/svg-files/AJ_Digital_Camera.svg > > it works. So I guess it's something with the SVG file? > > MapServer version 8.0.1 PROJ version 7.2 GDAL version 3.4 OUTPUT=PNG > OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE > SUPPORTS=CAIRO SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV > SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT > SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER > SUPPORTS=SOS_SERVER SUPPORTS=OGCAPI_SERVER SUPPORTS=FASTCGI > SUPPORTS=GEOS SUPPORTS=PBF INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL > INPUT=SHAPEFILE INPUT=FLATGEOBUF > > > ___ > MapServer-users mailing list > MapServer-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/mapserver-users > ___ MapServer-users mailing list MapServer-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
[MapServer-users] Some remote SVG files doesn't in 8.1
I've a MapFile with a point layer using a class style with a SVG symbol: CLASS NAME 'point' STYLE SYMBOL 'https://raw.githubusercontent.com/NordjyllandsTrafikselskab/gisimages/ca64d7a849c7cf0290ec41ec263a97b9195d0ff8/01.01.01.Bus.svg' END END In 7.6 this works fine, but in 8.1 the SVG symbol is not showing (no errors but the image is blank). But if change the SVG file to e.g.: https://dev.w3.org/SVG/tools/svgweb/samples/svg-files/AJ_Digital_Camera.svg it works. So I guess it's something with the SVG file? MapServer version 8.0.1 PROJ version 7.2 GDAL version 3.4 OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=OGCAPI_SERVER SUPPORTS=FASTCGI SUPPORTS=GEOS SUPPORTS=PBF INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE INPUT=FLATGEOBUF ___ MapServer-users mailing list MapServer-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users