Results 1 to 5 of 5

Thread: How to get the native QStyle subclass?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jun 2007
    Location
    India
    Posts
    1,042
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows
    Thanks
    8
    Thanked 133 Times in 128 Posts

    Default Re: How to get the native QStyle subclass?

    yes the style has been created but its not used until you allow it to.

    Qt Code:
    1. main()
    2. {
    3. QApplication app(argc,argv);
    4.  
    5. QStyle *nativeStyle = app.style();
    6. //do whatever you want to do with style;
    7.  
    8. //Style would be used now.
    9. mw.show();
    10.  
    11. return app.exec();
    12. }
    To copy to clipboard, switch view to plain text mode 

  2. #2
    Join Date
    Jul 2009
    Posts
    74
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows
    Thanks
    12
    Thanked 1 Time in 1 Post

    Default Re: How to get the native QStyle subclass?

    I'm inside a library that only gets called after the QApplication::style() has already been modified.

Similar Threads

  1. Replies: 2
    Last Post: 14th July 2011, 12:28
  2. Qt has wchar_t as non-native?
    By Wasabi in forum Newbie
    Replies: 7
    Last Post: 22nd December 2010, 20:08
  3. Replies: 8
    Last Post: 12th February 2010, 02:41
  4. using native kde-dialogs
    By #andi# in forum Newbie
    Replies: 2
    Last Post: 11th August 2009, 10:50
  5. Can Native Api be Used?
    By iGoo in forum Qt Programming
    Replies: 1
    Last Post: 25th May 2006, 11:44

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.