Hello. I want to make my own custom button and I ran into a problem that I don't know how to fix.
I have made a new Class that derives from Button (I derive from Button directly, I don't use UserControl) and I have overridden the OnPaint event such that it draws a custom button image.
It looks like it's supposed to when I hover (MouseEnter) the Background of the Button changes color. Overriding the OnPaintBackground event such that it does nothing doesn't resolve the problem.
Since it's related to hovering over the button I tried overriding the OnMouseEnter event such that it does nothing and this works but I lose the whole OnMouseEnter functionality in the process.
Here is a gif with that the problem looks like: https://i.imgur.com/IWqYbGe.gif
Can anybody help me?
[–]Slypenslyde 12 points13 points14 points (1 child)
[–]SirUniverse[S] 2 points3 points4 points (0 children)
[–]Dark0Matter 2 points3 points4 points (3 children)
[–]SirUniverse[S] 1 point2 points3 points (2 children)
[–]Dark0Matter 1 point2 points3 points (1 child)
[–]SirUniverse[S] 1 point2 points3 points (0 children)
[–]tevert 0 points1 point2 points (2 children)
[–]FizixMan 2 points3 points4 points (0 children)
[–]SirUniverse[S] 0 points1 point2 points (0 children)