PDA

View Full Version : Custom look for buttons



harvey_slash
3rd October 2013, 14:18
I want to personalize the look of my app.
I am making a calculator, and want to make the buttons look different.
they should look like the google calculator.
(should have pointed edges.)
when I press, it should show another image(a pressed form )
and when I hover, it should show another image .
I am totally new, so how do I start ?

I used this in my button pusButton stylesheet
QPushButton#pushButton {
background-color:yellow
}
QPushButton#pushButton:pressed {
background-color: rgb(224, 0, 0);
}


QPushButton#pushButton:hover {
background-color: rgb(224, 255, 0);

}

when I hover my mouse over it, it changes color, like I expect it to , But the hover color remains even when I press the button. I tried changing the order, but its still the same problem . little new in Qt.