Results 1 to 2 of 2

Thread: qt #include question

  1. #1
    Join Date
    Jul 2008
    Posts
    12
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default qt #include question

    I just have a general question.

    When including QT libraries, is it better to

    a)
    Qt Code:
    1. #include <QDomDocument>
    2. #include <QDomElement>
    3. #include <QDomText>
    4. ...More Includes...
    To copy to clipboard, switch view to plain text mode 

    or

    b)
    Qt Code:
    1. #include <QtXml>
    To copy to clipboard, switch view to plain text mode 

    I'm just wondering, at what point should you just use the overall generic include of the whole QtXml library, rather than each specific class/object that you use?

    Is there speed benefits to using one or the other?

  2. #2
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: qt #include question

    See thread: Qt modules
    J-P Nurmi

Similar Threads

  1. QApplication: no such file or directory
    By jochen_r in forum Newbie
    Replies: 13
    Last Post: 15th November 2008, 21:46
  2. Error: Using Multiple files
    By 3nc31 in forum Qt Programming
    Replies: 1
    Last Post: 22nd November 2007, 09:23
  3. Painting problem
    By Mel in forum Qt Programming
    Replies: 10
    Last Post: 8th May 2007, 21:38
  4. Can't create an object : initialisation problem ?
    By Nyphel in forum Qt Programming
    Replies: 5
    Last Post: 12th March 2007, 09:07
  5. use button from another Window
    By raphaelf in forum Qt Programming
    Replies: 11
    Last Post: 2nd March 2006, 20:31

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.