Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Open Source > BOOK Beginning Linux Programming, 3rd Edition
| Search | Today's Posts | Mark Forums Read
BOOK Beginning Linux Programming, 3rd Edition
This is the forum to discuss the Wrox book Beginning Linux Programming, 2nd Edition by Richard Stones, Neil Matthew, Alan Cox; ISBN: 9780764543739
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK Beginning Linux Programming, 3rd Edition section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old October 14th, 2005, 08:19 AM
Registered User
 
Join Date: Oct 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Qt programming, bugs in first programming

Hi,

In chapter 17. Qt programming, the first programm contains bugs.

#include <qapplication.h>
#include <qmainwindow.h>

int main(int argc, char **argv)
{
     QApplication app(argc, argv);
     QMainWindow window(); /* Here is bug. it should
                            'QMainWindow window;' */
     app.setMainWidget(window); /* Here is bug. it should be
                             'app.setMainWidget(&window);' */
     window.show();
     return app.exec();
}

i am using qt-3.3 version. and it didnot have any library naming 'libqt'. insted it has 'libqt-mt' library. so i have to change the library name in command to compile application.

> g++ -o qtl qtl.cpp -I$QTDIR/include -L$QTDIR/lib -lqt

Here i changed -lqt (as given in book) to -lqt-mt, then it worked.

regards,
sateeshgalla.



Similar Threads
Thread Thread Starter Forum Replies Last Post
device DLL programming in client side programming hendyhanusin ASP.NET 1.0 and 1.1 Professional 2 February 19th, 2009 12:01 PM
Programming help RatanKumar Intro Programming 1 September 27th, 2007 03:40 PM
device DLL programming in client side programming hendyhanusin ASP.NET 1.0 and 1.1 Basics 0 March 21st, 2007 08:05 AM
device DLL programming in client side programming hendyhanusin ASP.NET 2.0 Professional 1 March 21st, 2007 08:04 AM
C/C++ Programming aashiqbabuma Forum and Wrox.com Feedback 1 August 19th, 2005 02:33 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.