java - Partially transparent images in javafx -


i making project in eclipse. have uploaded .png file using 'image view' option.it has transparent areas .i want write code such detects click of user's mouse when on opaque area , take user new window defined me.

this code should work in circumstances.

imageview.addeventfilter(mouseevent.mouse_clicked, e -> {     color color = image.getpixelreader().getcolor(e.getx(),e.gety()));     if(color.getalpha() != 0)     {         //execute code here     } }); 

Comments

Popular posts from this blog

php - How to add and update images or image url in Volusion using Volusion API -

javascript - jQuery UI Splitter/Resizable for unlimited amount of columns -

javascript - IE9 error '$'is not defined -