I would like to change all of the h1 elements in all of the QLabels in my program to be blue. Is there an easy way to do this with a style sheet?

I tried:

Qt Code:
  1. QLabel.H1 { color: blue }
To copy to clipboard, switch view to plain text mode 

and

Qt Code:
  1. QLabel::H1 { color: blue }
To copy to clipboard, switch view to plain text mode 

and a few other things that I thought might work, but no luck so far.

I am not clear from the documentation if this is something that is supported or it is just matter of bad syntax. Has anyone done this before? Is it possible to use style sheets to control the formatting of rich text elements in a QLabel? Is there a different way to get consistent formatting of particular elements within the GUI that I should be using?