Asperamanca
4th November 2010, 14:51
Is it possible to use Style Sheets in custom, not QWidget-derived classes?
For example, I have a value scale object that draws using GraphicsView. Let's say I want to set it's background color using style sheets.
StyleSheet:
MyValueScale { background-color: yellow; }
Somewhere, I have a class that draws the value scale. Is there a way to access the palette for "MyValueScale", and therefore find out the user wants the background color "yellow"?
For example, I have a value scale object that draws using GraphicsView. Let's say I want to set it's background color using style sheets.
StyleSheet:
MyValueScale { background-color: yellow; }
Somewhere, I have a class that draws the value scale. Is there a way to access the palette for "MyValueScale", and therefore find out the user wants the background color "yellow"?