Alex Rivera | Logout

Mouse event on transparent background

Asked 2011-11-03T07:10:10.957
14

I have create several canvas with transparent background and wanna make some move event on it.

However, I found that all mouse event (e.g. MouseLeftButtonDown) cannot function of the background of the canvas is Null or Transparent. But if I set the background to some solid color (say, red or blue), the mouse event function well.

Why?

Could I make the mouse event function properly with transparent background?

Thank you!

Edit
Report

1 Answer

9

Note that there is a difference in setting the background to transparent as opposed to not setting it (or setting it to null). My experience is that hit-testing works on transparent, but not on a null background.

answered 2011-11-03T07:23:47.187

Your Answer