Results 1 to 4 of 4

Thread: C++ code and Qt

  1. #1
    Join Date
    Jan 2012
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default C++ code and Qt

    Hi. Just been evaluating Qt and looks really good for GUI development across platforms.

    However I had imagined C++ would fully integrate into a Qt GUI. For example I wanted to use fstreams to read and write files when a button was clicked. But all examples seem to show the use of QFile.

    Have I missunderstood and is it not possible to drop the hundreds of classes and wadges of code I have (all C++) into Qt GUIs?

    Thanks for any help

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

    Default Re: C++ code and Qt

    You can use any C++ class you want. There are advantages of using QFile however if your fstream based code works, there is no reason to change it.
    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 2012
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: C++ code and Qt

    Many tx wysota. I thought that must be the case and indeed have just got one to work.

    The reason I don't want to get unnecessarily hooked into Q stuff is to leave a future escape tunnel. 95% of what I will end up with is already well established and been in use in one form or another for 20 years. And it is all native C++, C, with a little shell script and HTML with Jscript.

    As for my evaluation I found a few glitches in Qt on Windows but with Linux it seems really solid. Cheers

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

    Default Re: C++ code and Qt

    Trust me, if you sink into Qt, you'll never want to use that escape tunnel
    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.


Similar Threads

  1. how to use C code in qt?
    By shakthi in forum Qt Programming
    Replies: 5
    Last Post: 24th July 2011, 17:46
  2. int to hex code
    By nowire75 in forum Newbie
    Replies: 5
    Last Post: 14th January 2008, 17:00
  3. SSH through Qt code
    By lrrcaldas in forum Qt Programming
    Replies: 2
    Last Post: 28th August 2007, 15:45
  4. Pasting code from code tag in emacs
    By Gopala Krishna in forum General Discussion
    Replies: 0
    Last Post: 16th February 2007, 05:47
  5. C++ code
    By therealjag in forum Newbie
    Replies: 8
    Last Post: 14th March 2006, 19:48

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.