Results 1 to 3 of 3

Thread: About include 'styles'

  1. #1
    Join Date
    Sep 2010
    Posts
    654
    Thanks
    56
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default About include 'styles'

    I have seen a few distinct include sintax :

    #include <QtGui/QApplication>
    #include <QApplication>
    #include "QtGui/QApplication"

    All of them are valid ? Any explanation?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: About include 'styles'

    Quote Originally Posted by tonnot View Post
    All of them are valid ?
    Yes.
    Any explanation?
    The explanation is all three syntaxes are valid for C/C++.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: About include 'styles'

    Qt Code:
    1. #include "A"
    To copy to clipboard, switch view to plain text mode 
    Looks for A in the source directory first, then in the other directories known by the compiler.

    Qt Code:
    1. #include <A>
    To copy to clipboard, switch view to plain text mode 
    Does not look for A in the source directory first, but in the directories known by the compiler.

    Qt Code:
    1. #include <A/B>
    To copy to clipboard, switch view to plain text mode 
    Looks for A/B in the know directories.

    Edit: this is basic C++ by the way. If you look this up in google or any good book store you find tons of information about it.
    Last edited by tbscope; 21st September 2010 at 18:36.

Similar Threads

  1. GUI Styles
    By dsmcc in forum Qt Programming
    Replies: 1
    Last Post: 19th November 2008, 15:58
  2. PyQt Styles
    By awestman in forum Qt Programming
    Replies: 0
    Last Post: 17th October 2008, 13:59
  3. Styles of scrollbar
    By zlosynus in forum Qt Programming
    Replies: 2
    Last Post: 7th August 2008, 14:33
  4. Problem with Qt4 Styles
    By drake1983 in forum Newbie
    Replies: 2
    Last Post: 10th February 2008, 03:11
  5. Styles - building
    By Salazaar in forum Newbie
    Replies: 10
    Last Post: 20th May 2007, 18:19

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.