Closed GoogleCodeExporter closed 9 years ago
Can you provide a link to a map that shows the problem or a link to a kml file
that will expose it?
I have an example here:
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_nonstandard_icon_test.html
But it shows stretching, not cutting.
I'm not sure this will be fixed. Do Google Maps or kmlLayers support custom
marker sizes?
Is there a mechanism in kml to specify the size of the icon?
The proposed change breaks scaling and I'm not sure it will work if the icon
image is not already in the browser's cache.
Original comment by geocodezip
on 29 Oct 2010 at 1:36
With that map and KML, just try to load the geoxml3.js, not from the polys
branch but from the trunk.
It shows stretching because the geoxml3.js from the polys branch scale the
marker, but if you use the trunk version, it cut the icons.
However, if you use the code I proposed, the not standard 32x32px icon shows
correctly; I attach the sample KML file you use in the example with the icons
changed so you can see it better and the html with the trunk version selected.
Original comment by alvaro.d...@gmail.com
on 29 Oct 2010 at 6:58
Attachments:
As far as I can tell, it works just fine in the polys branch.
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_custom_icon_polys_version.html
Both icons are cut off in the trunk:
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_custom_icon_trunk_version.html
but that version won't even load in IE6.
When I am satisfied with the polys version I will probably move it to the
trunk, until then, I can back port fixes to the trunk if there is a good reason.
Original comment by geocodezip
on 29 Oct 2010 at 8:22
Original comment by geocodezip
on 29 Oct 2010 at 8:23
It does look like the anchor is being set incorrectly to the middle of the icon
though. I added lines that should cross at the location where the icon is
anchored. That I will look into addressing in the development version.
Original comment by geocodezip
on 29 Oct 2010 at 9:31
Why to scale the icon if you can leave it with its original size?
Original comment by alvaro.d...@gmail.com
on 31 Oct 2010 at 10:41
KML supports scaling icons:
http://code.google.com/apis/kml/documentation/kmlreference.html#scale
geoxml3 in the polys branch currently supports that, breaking that would be a
regression.
Original comment by geocodezip
on 31 Oct 2010 at 11:44
I added an issue that I think is related:
http://code.google.com/p/geoxml3/issues/detail?id=44
Original comment by verm...@nurc.nato.int
on 13 Dec 2011 at 11:21
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_kmztest_linkto.html?filename=c
ustomIconKml.xml
Fixed in kmz branch
Original comment by geocodezip
on 23 Feb 2012 at 4:12
Original issue reported on code.google.com by
alvaro.d...@gmail.com
on 28 Oct 2010 at 10:15Attachments: