flowLayoutPanel's buttons' images disappearing

0
0

I have a FlowLayoutPanel with buttons in it, so far so good. But SOME of them and when certain conditions are met have their images vanish on hover, and don’t reappear unit I refresh the control (not the page though).

So, why some buttons? I don’t know, but those that disappear also have a slight decoloration to them, like a css filter with transparency set to 5%. Those buttons, when hover with the mouse, will have its image removed, resulting in a button that is, at least as far as the user is concerned, invisible.

 

Crazy part is all buttons are copy and pasted from an original one, but will “disappear” if and only if:

-they are part of the chosen ones (those that look slightly dimmer)

-they have a css class (doesn’t matter if that class has any style ruleset applied or even if it was called by the stylesheet)

-they have a function bound to an event

-it’s  the very first time the control is loaded.

 

What i’ve tried:

-deleting the css file

-commenting out those css rules that directly affect the classes used with the buttons

-checking the code to see if at any point it overwrites the source image

-comparing the properties and designer code of those buttons affected by this behaviour and those that act normally

-checking if it’s the function bound to the event the one causing the problems

 

What I could do:

-deleting the classes and try to do everything via code with different event functions(really don’t think is neither the most efficient nor the most correct way to do this)

-use inline css with all my buttons, not a good idea either imo

-unaliving myself. Currently the best option but i’m open to suggestions

 

 

  • You must to post comments
0
0

Hi Pablo,

Would it be possible to wrap up a small reproducible test sample to check exactly what went wrong?

In general, we recommend using Theme Mixins or Custom Themes if you’re going to apply any kind of customization for Wisej.NET components, it’s much better than using CSS!

From what I understand, looks like something is overriding the CSS styles of the controls, hence why we would need the test case!

HTH,
Alaa

  • You must to post comments
0
0

fig1: the buttons in question. Notice they all look gray except for the righter most one which looks black (as it should)
fig2:the pencil button after its image got removed on hover
fig3: that’s what the buttons look like after reloading the control by changing to a different one and then going back to it
fig4: the designer code of two buttons, the one on top is one of the faulty ones and the one on the bottom a working one (note that is the exact same code)

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.