Results 1 to 2 of 2

Thread: Qt for non GUI apps?

  1. #1

    Question Qt for non GUI apps?

    Hi.

    I want to write a non-GUI application for Linux (both desktop and embedded) and Windows.

    I need the usual classes: networking, threads, etc., and the ones I was using before were tied to my previous employer.

    It is my understanding that Qt has these sorts of classes, works on Windows and Linux, and is now LGPL. But can I use these classes for small, non-GUI apps?

    I might want to add an optional GUI later, so it would make that easier for me if I were to start using Qt now.

    Also, most of the publicly available code uses the C++ STL. I've read that Qt doesn't use the STL. Is that still true?

  2. #2
    Join Date
    Mar 2008
    Location
    Houston, Texas, USA
    Posts
    277
    Thanks
    9
    Thanked 17 Times in 17 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Maemo/MeeGo

    Default Re: Qt for non GUI apps?

    Yes you can use all the non-GUI classes in a console based app just replace QApplication with QCoreApplication. Yes Qt can use STL. There are functions to convert Qt contains to STL and vice versa and more. But that is only to allow adaption to non Qt libraries. You shouldn't use it in your code though. You should use Qt wherever possible unless you have a perfect valid reason to not use the Qt contains and what not. But you have to enable STL when compiling. Gentoo doesn't offer it I think for me. I don't know.
    Qt-4.7.3 | Gentoo ~amd64 | KDE-4.7
    Aki IRC Client for KDE4 | Qt Documentation

Similar Threads

  1. add an apps to the designer widget box
    By adamatic in forum Qt Tools
    Replies: 1
    Last Post: 5th March 2009, 07:31
  2. How to ship Qt apps?
    By Morea in forum Installation and Deployment
    Replies: 2
    Last Post: 22nd June 2008, 13:22
  3. QT 4.4: CLI apps?
    By Hossie in forum Qt Programming
    Replies: 6
    Last Post: 19th May 2008, 12:37
  4. signals and slots between 2 Apps?
    By nupul in forum Qt Programming
    Replies: 9
    Last Post: 12th April 2006, 12:38
  5. Console apps in Kde Qt
    By peedarp in forum Qt Programming
    Replies: 5
    Last Post: 1st February 2006, 11:43

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.