technoViking
21st June 2010, 22:47
hi guys, I've spent HOURS trying ot figure this out and no luck.
Basically I want the combo boxe's font color to be white.
Currently when the user clicks the combo box all the drop down items font color will be WHITE which is correct.
But once they select the item they want, the drop down will dissapear and the item will be in the combobox but it will be black.
So drop down works, but when its not in drop down mode the font color is black which I'm trying to make white.
Here is the QSS I'm using:
myWidget QComboBox
{
selection-color: rgb(255, 255, 255);
color: rgb(255, 255, 255);
background-color: rgb(0, 28, 53);
font: 18pt "Arial";
border: 1px black;
border-image: url(:/Resources/down.png) 10 10 10 10;
}
myWidget QComboBox:on
{ /*shift the text when the popup opens */
selection-background-color: rgb(108, 149, 59);
color: rgb(255, 255, 255);
}
myWidget QComboBox:!on
{ /* shift the text when the popup opens */
selection-background-color: rgb(108, 149, 59);
color: rgb(255, 255, 255);
}
QComboBox QListView
{
background-color: rgb(0, 28, 53);
}
I also had a image I wnated to use instead of using the standard icon for the down arrow on the combo box but for some reason that isn't showing up either.
Any help would be great.
Basically I want the combo boxe's font color to be white.
Currently when the user clicks the combo box all the drop down items font color will be WHITE which is correct.
But once they select the item they want, the drop down will dissapear and the item will be in the combobox but it will be black.
So drop down works, but when its not in drop down mode the font color is black which I'm trying to make white.
Here is the QSS I'm using:
myWidget QComboBox
{
selection-color: rgb(255, 255, 255);
color: rgb(255, 255, 255);
background-color: rgb(0, 28, 53);
font: 18pt "Arial";
border: 1px black;
border-image: url(:/Resources/down.png) 10 10 10 10;
}
myWidget QComboBox:on
{ /*shift the text when the popup opens */
selection-background-color: rgb(108, 149, 59);
color: rgb(255, 255, 255);
}
myWidget QComboBox:!on
{ /* shift the text when the popup opens */
selection-background-color: rgb(108, 149, 59);
color: rgb(255, 255, 255);
}
QComboBox QListView
{
background-color: rgb(0, 28, 53);
}
I also had a image I wnated to use instead of using the standard icon for the down arrow on the combo box but for some reason that isn't showing up either.
Any help would be great.