简体   繁体   中英

CSS in Qt Creator

I can't find anything on this topic, is it possible to use CSS files in Qt or do I have to use setStyleSheet on every element I want to style?

I can't say its very maintainable if I have to write all the styles in quotes.

You can use -stylesheet to specify a stylesheet on the command line. In addition, you could load your .qss file from a file or a resource and then call setStylesheet on your QApplication instance.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM