Are Qt's stylesheets really handling _dynamic_ properties?

后端 未结 4 401
名媛妹妹
名媛妹妹 2021-01-04 01:47

Is Qt\'s dynamic properties really so dynamic with stylesheets?

I have the basic example from stylesheets and dynamic properties:

/*stylesheet:*/
*[f         


        
4条回答
  •  粉色の甜心
    2021-01-04 02:20

    Qt has the following recommendation in their FAQ:

    style()->unpolish(theWidget);
    style()->polish(theWidget);
    

    They also say you can reset the stylesheet by doing the following but it is more expensive:

    setStyleSheet(styleSheet());
    

提交回复
热议问题