[Solved]How to view Qt applications in different styles?



  • Hi,

    I heard Qt applications can easily preview in different styles.

    I asked my colleague and he says I have to use -style motif as arguments in run settings. It change the appearance of my app, but i need to try out all the styles.

    So,

    1. What are the commands should I use ?

    2. Are there any way to change styles? I found someone says use @QApplication::setStyle(new QPlastiqueStyle)@

    3. what is the best way?

    Thanks in advance..



  • Hello ~Hareen Laks

    Both ways are okay, you can set style via command line argument, like ("-style <stylename>") or via runtime command (qApp->setStyle(QStyle*)). For trying all styles I would recommend you to use the second one, but you can use the first one also



  • Thank you tucnak..

    I enjoyed lot of styles except some are not possible with my OS. :)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.