Changing pixmaps on a label

Tim Wojtulewicz Tim.Wojtulewicz at NAU.EDU
Wed Apr 12 04:44:54 BST 2000


I have a small widget in a project that I'm working on that consists of
three QLabel objects, each holding pixmaps.  It works as a sort of
status bar with three colored (green, yellow,red) lights.  I'm having a
small problem with switching what pixmaps are displayed.

I have three functions called setRed, setGreen, and setYellow.  When
I call one of them, it changes the pixmap for one so it looks like an
'on' state, and turns the other two to an 'off' state.  The first time I
call one of the functions, it works as it should.  If I try to change it
again, nothing happens.  The pixmaps stay the way they are.  Anyone have
any ideas?

Tim





More information about the KDevelop mailing list