Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add optional marker menu #24

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

danielroedl
Copy link

A custom right click menu can be added to a marker with

myMenu = {
  # key is the title and value is the function to call
  'My fancy marker menu entry 1': function1,
  # separators can also be added
  '-': None,
  'And a second entry after the separator': function2
}
map_widget.set_marker(x, y, menu=myMenu)

@danielroedl
Copy link
Author

danielroedl commented Jun 14, 2022

Maybe it is a good idea to add this menu option also to CanvasPath and CanvasPolygon too. What do you think?

EDIT: Done

A custom right click menu can be added to a marker with

myMenu = {
  # key is the title and value is the function to call
  'My fancy marker menu entry 1': function1,
  # separators can also be added
  '-': None,
  'And a second entry after the separator': function2
}
map_widget.set_marker(x, y, menu=myMenu)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant