Hi,
I have written a custom maptool where I use overlays to show graphic information on a map view.
In the OnToolActivateAsync I call the AddOverlay method to add the graphic overlay and in my OnToolMouseMove I call the UpdateOverlay method. To this point, everything worked fine.
But know I had the requirement that the overlay symbol should scale according to some reference scale.
In the API there is a overload for the AddOverlay method where I can set the reference scale:
https://pro.arcgis.com/en/pro-app/latest/sdk/api-reference/index.html#topic27602.html
But there is no similar overload for the UpdateOverlay method!
The result is now that when the tool is activated, the graphic is scaled accoring to my reference scale but as I move the mouse, the reference scale setting is lost and the overlay graphics becomes bigger.
I helped myself with destroying the overlay with Dispose and calling AddOverlay with the reference scale parameter in the OnToolMouseMove but that causes a slight flickering of my overlay graphic.
Is there a better way to do this?
Why is there no overload for UpdateOverlay with a reference scale parameter?