[Geojs-users] Need help to strokeopacity while creating multiple annotation

Bhupendra Singh Bhupendra.Singh1 at india.nec.com
Sun Mar 8 00:47:34 EST 2020


Thanks David for your reply.

I tried both the options mouseover/mouseout or mouseon/mouseoff but the results are same. Only one annotation is getting highlighted on mouse  hover over. I am using below code.

line.geoOn(geo.event.feature.mouseover, (evt) => {
                                  evt.data.selected = true;
                                  line.modified().draw();
                                  $('.geojs-layer').css('cursor', 'pointer');
                                });
                                line.geoOn(geo.event.feature.mouseout, (evt) => {
                                  evt.data.selected = false;
                                  line.modified().draw();
                                  $('.geojs-layer').css('cursor', 'inherit');
                                  $("#geojs .geojs-layer").css("pointer-events", "auto");
});

Thanks & Regards,
Bhupendra

From: David Manthey [mailto:david.manthey at kitware.com]
Sent: 07 March 2020 03:24
To: Bhupendra Singh <Bhupendra.Singh1 at india.nec.com>
Cc: geojs-users at public.kitware.com
Subject: Re: Need help to strokeopacity while creating multiple annotation

If you are using feature events, are you using mouseon/mouseoff or mouseover/mouseout?  mouseon and mouseoff are for the "topmost" element (though a function can override what it means to be topmost).  mouseover and mouseout apply to all features (see  https://opengeoscience.github.io/geojs/apidocs/geo.event.feature.html#.event:mouseoff, etc.)

On Fri, Mar 6, 2020 at 4:15 AM Bhupendra Singh <Bhupendra.Singh1 at india.nec.com<mailto:Bhupendra.Singh1 at india.nec.com>> wrote:
Hi Geojs team,

I observed one behaviour after implementing the Geo JS code , the code is only highlighting the latest created annotation all other annotation are not highlighting on mouse hover over.

In the below example, ANO3 is changing the strokeopacity  with mouse hover over if I will create the new annotation on the page then that will be only highlighted on mouse over hover. I need strokeopacity  should work for all the created annotation.

[cid:image001.png at 01D5F558.9D8F0260]


Thanks & Regards,
Bhupendra
________________________________
The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. It shall not attach any liability on the originator or NECTI or its affiliates. Any views or opinions presented in this email are solely those of the author and may not necessarily reflect the opinions of NECTI or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately.


--
David Manthey
R&D Engineer
Kitware Inc.
(518) 881-4439
________________________________
The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. It shall not attach any liability on the originator or NECTI or its affiliates. Any views or opinions presented in this email are solely those of the author and may not necessarily reflect the opinions of NECTI or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/geojs-users/attachments/20200308/a39506e8/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 24986 bytes
Desc: image001.png
URL: <https://public.kitware.com/pipermail/geojs-users/attachments/20200308/a39506e8/attachment-0001.png>


More information about the Geojs-users mailing list