Can I use Qt Style Sheets with advanced widgets in Qt Creator?

I am trying to make a heavy rethinking of standard widgets using Qt style sheets. Therefore, having done most of this manually for different widgets using selectors #objectName, I decided to somehow group similar widgets.

For example, I have several QFramesthat act as headers in internal forms. And I want them all to have the same stylesheet. One way to do this is to use a naming convention (this is my fallback), i.e. QFrame[objectName|="prefix_"]. But I wanted to group my widgets into classes. So I created a simple placeholder class:

class HeaderFrame: public QFrame
{
public:
    HeaderFrame(QWidget *parent = NULL): QFrame(parent) {}
};

This allowed me to push all of these QFramesup HeaderFrames. After that I tried to install

HeaderFrame { background-color: red; }

stylesheet MainWindow ( HeaderFrames), . QtCreator , . , .

, Qt- (, QLabel, QFrame ..)? ?

+5
2

, . , - PaintEvent.

UPD: :

class Header1Label : public QLabel
{
    Q_OBJECT
    public:
    Header1Label(QWidget *parent = 0):QLabel(parent){};
    ~Header1Label(){};
};

:

Header1Label
{
    font-size:14px;
    font-weight:900;    
}
+3

class-name , QStringList, .class-name.

0