Skip to main content

Questions tagged [leaflet.draw]

Vector drawing and editing plugin for Leaflet

leaflet.draw
0 votes
0 answers
22 views

How can i pass in coords to draw the correct shape on an IMAGE?

can I pass actual x / y cords to Leaflet.js to draw a shape? - I have tried using actual cords and the shape is nothing like I expect - also SetView cords can I pass them here too ? Code: var map = L....
Tony Blaikie's user avatar
0 votes
1 answer
58 views

Trouble loading markers inside a polygon using Leaflet.js, FreeDraw, and Laravel

I use Leaflet.js, FreeDraw, and Laravel to create a real estate system. The functionality I am trying to set up is that when the user draws a polygon on the map, it should trigger an API call and only ...
Daniel el khal's user avatar
1 vote
0 answers
71 views

Changing Colours of Leaflet Map

I wonder if and how it is possible to change the color of the map (individual countries, backgrounds and lines) in Leaflet? I have simply created the basic code of a leaflet map as specified in the ...
Tim Schäflein's user avatar
0 votes
0 answers
20 views

leaflet (angular) dosn't show overlay-pane

I have the next map with leaflet: private initializeMap(): void { let ubicacion = this.obtenerUbicacionActual(); const center: LatLng = latLng(ubicacion[0], ubicacion[1]); // where i am ...
user2315402's user avatar
1 vote
0 answers
69 views

Leaflet draw polygon is rendering/drawn wrongly shifting bit away from selected position in Angular 17 with ssr enabled

We are using angular 17 and we have used leaflet and leaflet draw JavaScript plugin to plot the map and want to draw polygons, rectangle over it and get the boundary co-ordinates of the same. But when ...
Yogesh Shankar Naik's user avatar
0 votes
0 answers
128 views

how to enable leaflet edit & delete buttons in leaflet-draw-toolbar by default in vue2

I am using leaflet map library. I am facing issue with leaflet-draw-toolbar in which I have edit & delete buttons but these buttons are disabled by default. please provide me solution by which I ...
Malik Tayyab's user avatar
0 votes
0 answers
44 views

how to add new polygon layers to already drawn ones

how to add new polygons to an existing layer, so as not to completely redraw, but only add new ones? the current code completely redraws the entire layer, but it is necessary for new zones to be added ...
Александр Плетнев's user avatar
0 votes
0 answers
131 views

Create a wider selection area to select the lines on react-leaflet map

Having difficulty in selecting the lines on react-leaflet map, so I have followed the below solutions, https://gis.stackexchange.com/questions/466747/create-wider-selection-area-to-select-lines-on-...
Kishor's user avatar
  • 200
0 votes
0 answers
154 views

Enable edit polygon on click in leaflet maps

I'm using below function to get geography data from backend as json and then draw polygon using leaflet: function drawAreas() { $.ajax({ type: "POST", url: "...
Behnam Faghih's user avatar
0 votes
1 answer
100 views

Leaflet: Error while trying to get a GeoJSON from multipolygon Layer

The issue is this one: I successfully could implmement a MultiPolygon Layer in Leaflet, but I'm getting an error while trying to convert it to a GeoJSON object. My code is this one: let ...
Leandro Caplan's user avatar
0 votes
1 answer
111 views

Calling cancel button while drawing in Leaflet-Draw

I am Creating Map with some areas drawn as polygons. Each area have property AreaNumber. AreaNumber is given in input under map. Problem is: How to cancel drawing if AreaNumber is not written in input?...
FallenOne's user avatar
1 vote
1 answer
343 views

Leaflet Draw: Attempting to erase a drawn shape, by clicking outside of it after drawing it

I'm developing a Laravel app with Leaflet, and trying to implement some funcionalities with the Leaflet Draw plugin. What I'm trying to do is this: Drawing a polygon, rectangle or circle with Leaflet ...
Leandro Caplan's user avatar
0 votes
1 answer
320 views

Prevent draggable circle using Leaflet circle and leaflet-draw library

I have a circle that I add to the map when you click on a specific point (centroid of that circle will be where the point is) and you can edit the circle, meaning you can resize it using the gripper ...
fairlyMinty's user avatar
2 votes
1 answer
175 views

Leaflet.Path.Transform - is there a way to add edge markers in the middle of each border?

I want to add circles in the middle of each border (only visually). Is there a way to do it? There are handlerOptions but I couldn't find something like that there.
erez chen's user avatar
0 votes
0 answers
98 views

Leaflet Draw - Selecting 1 Draw Option then another causes Drawing to drag map instead of shape

When attempting to draw, if you first select Draw Circle then select Draw Rectangle then go to click on the map, instead of beginning the drawing and dragging the shape out, the shape gets an initial ...
Chaz's user avatar
  • 1

15 30 50 per page
1
2 3 4 5
21