Page 1 of 1

QT and code completion

Posted: Fri Apr 23, 2010 10:58 pm
by ogee77
Hi,

I've created a QT project using QtMake and successfully compiled a sample application, which uses QString.

#include <qstring>
#include <cstdio>
#include <vector>

int main(int argc, char **argv)
{
QString str;
std::vector< int > v;
str = "Hello world from QT";
printf("%s\n", str.toLocal8Bit().constData());

return 0;

}

I went through documentation on code completion performing all the steps, including full retag of the workspace
and I can't get code completion working for QString. When I type 'str.' nothing happens. When typing '#include <' and
hitting Ctrl+Space a list pops up but it does not contain qstring.h.


My global include parser path is:

C:\wxWidgets-2.8.10\include
C:\MinGW-4.4.1\include
C:\MinGW-4.4.1\lib\gcc\mingw32\4.4.1\include\c++
C:\Qt\2010.02.1\qt\src\corelib\tool //it's where QString resides

My global exclude parser is:

C:\wxWidgets-2.8.10\include\univ
C:\wxWidgets-2.8.10\include\unix
C:\MinGW-4.4.1\lib\gcc\mingw32\4.4.1\include\c++\debug

The workspace parser paths are empty.

I have CodeLite rev.4059, my machine is Windows XP.

Regards,
Paul

Re: QT and code completion

Posted: Sat Apr 24, 2010 8:20 am
by eranif
Your path is wrong.

You should set it to:

Code: Select all

C:\Qt\2010.02.1\qt\include\QtCore
Retag your workspace and it will work.
Eran

Re: QT and code completion

Posted: Sat Apr 24, 2010 12:13 pm
by ogee77
Indeed.
Thanks!