Click events for images

Hi,

I want to have an interface with an image. Currently I have an image displayed with the PNGView. Is it possible to;

  1. Capture the click events and return the location of the mouse
  2. Add a ‘marker’ to the image where the user has click (similar to the map marker function)

Thanks

Hi Charlie,

Welcome to the Community! View interactions are currently only limited to the MapView, but will be extended soon to the GeometryView, and hopefully later to other views as well.

For more information regarding map view interaction, refer to this link.

To help in the design of our features, we would like to get a good understanding what the problem or limitations are. Could you elaborate on what you are trying to achieve with adding a marker to the image?

Hi @mslootweg,
we would like to pick some point on an image and the coordinate of that point related to the image will be processed with some calculations.
At the same time, it would be nice to leave on the image a marker showing where the selection was taken.
We were thinking to use a label or having a pre-loaded image that we can use like a marker.

If the only view interaction is on a map, this means we have a map in the background and this is not ideal for what we are looking for.
Seams that every app we are developing required something that MapView has but we don’t have the map in the background.

Thanks @sonomirco ! We have detailed this feature request/use case internally, which will help in forming a solution for the platform.

1 Like

Hi @sonomirco you mentioned that the coordinate will be processed, but I’m wondering what this coordinate means in your calculation. Does it make sense to define some coordinate system, or would it be sufficient to obtain for example a percentage of the width and height w.r.t. the top-left corner?

And what is the image in your case?

Sorry, I didn’t look at the thread name, I thought we were talking about finding the location on a map.

Hi @khameeteman, I think a percentage of the width and height would work well. In our case we want to obtain the location of a user’s click on an image of a boreholde diagram to measure a certain distance.