Closed samipuro closed 4 years ago
That sounds like a good idea. I will have a look what needs to be modified.
LOL. No changes needed at all because it is already supported: just set fill: true
var Geodesic3 = L.geodesic([], {
weight:3,
opacity:1,
fill: true,
color: 'green',
steps: 40
}).addTo(map);
Geodesic3.createCircle(calgary, 2000000);
I will add this info to the readme and the examples.
Thanks for the info, appreciated. Filling works fine now.
However it still struggles to draw it correctly for a very large radius circle, attached an example with a 4300 nautical mile (8000km) circle centered at Atlanta airport
I'm not sure what can be done about that. Let me think for a while.
When dragging or zooming the map up to the point that the lower part of the circle (southmost latitude) gets outside of the map boundaries, then the filling of the circle doesn't work as expected. Attached two examples.
Yeah I am seeing the same issue as @GabrielSampol when making large circles.
In addition to the unfilled "triangles" I am seeing I am seeing some unfilled "boxes" when using a circles when zooming in at certain levels. I am also using leaflet.markercluster to display marker clusters.
I will address this issue during refactoring (#40) that is currently in progress.
This is fixed with v2.1.0+.
Terrific news, thanks @henrythasler !
Ah, I am realizing we were using the ES5 branch but the recent changes are only applied to master. Is there any plan to update the ES5 branch at this point?
The toolchain creates distributions in the following formats:
cjs
- CommonJS, suitable for Node and other bundlers) dist/leaflet.geodesic.js
esm
- Keep the bundle as an ES module file, suitable for other bundlers and inclusion as a Githubissues.
[enhancement request]
Hi,
This plugin is really helpful for us, but one crucial feature is missing.. Or then I am just missing how to use it ;)
Namely the ability to fill a geodesic circle with a certain/defined color, in a similar manner like a normal circle can be filled in Leaflet's normal circle function (opacity and color for the fill).