Skip to main content

I’m trying to display a circle on the map component in the universal GUI (2022.2.13 b2.0) But nothing I do seems to alter the size of the circle. I’ve tried giving it two coordinates hoping that this would set the size but the circle remains the same.

 

{

        "CoordSets": C

                

                       {

                               "Lon": "10.865400",

                               "Lat": "55.565922"

                       },

                       {

                               "Lon": "10.865400",

                               "Lat": "56.0150816223465"

                       }

               ]

        ]

}


The docs don’t ever seem to mention the circle geometric type for the map component. How is this supposed to work?

Hi Jitse,

The radius of a circle is currently hard-coded set to 200. The coordinates are used for the center of the circle.

Maybe use some custom css to tweak it for now?

Kind regards, Erik


Eventually the GUI should listen to something like this:

{
"CoordSets": [
[
{
"Lon": "10.865400",
"Lat": "55.565922"
}
]
],
"Radius": 120
}

We will put this on our backlog.


This will be possible in the upcoming Universal GUI release (2022.2.15)


Just for future reference: what does the number set for radius represent? Pixels? Meters? Degrees longitude?


Great question! 

The maps component uses leaflet as the maps-marker provider and due to their documentation it’s in Pixels.


https://leafletjs.com/reference.html#circlemarker-option