googleway icon indicating copy to clipboard operation
googleway copied to clipboard

Changing the apparence of drawings using add_drawing()

Open thruesen opened this issue 3 years ago • 1 comments

Hi,

Is it possible to adjust the stroke_weight and color of the drawing? In particular, I am building a Shiny app where I need the user to draw a polygon on a satellite map, but the users complain that it really difficult to see the line while drawing:

image

thruesen avatar May 12 '22 13:05 thruesen

it certainly looks possible.

If you're happy to have a go at implementing a PR then the add_drawing() function call needs to accept the various storke_, fill_ etc. arguments. Then these lines need to be replaced to use the user-defined values.

The default values are defined here

Then the javascript functions should just work without needing any changes.

If you're happy to have a go at implementing a PR

If not I can't guarantee when I'll have time to add this myself.

dcooley avatar May 15 '22 23:05 dcooley