PDA

View Full Version : Qpriuatesignal undeclared



ChemistBob
5th January 2015, 00:53
I have several qt projects with the same problems. the first problem is
qpivatesignal has not been declared error! i am using my cell phone
i have a problem with the code i will describe the best i can. please bear with me. the problem to be the same code list several times in several header files. qobject.h qprocess.h qabstractitemmodel.h i am using qt creator. the code creating the problem is if !defied paren q underscore qdoc paren , qprivatesignal end if paren semicollon q-qdoc is all caps and capq-tcapp-rivatecaps-ignal now i created a header file qprivatesignal.h void qprivatesignal paren int value paren semicolon this did not work i would appreciate any help in solving this error

d_stranz
5th January 2015, 18:44
if !defied paren q underscore qdoc paren , qprivatesignal end if paren semicollon q-qdoc is all caps and capq-tcapp-rivatecaps-ignal

Your post is unintelligible.


i am using my cell phone

If you mean you are trying to use your cell phone to post something to this forum, then hang up, find a real computer, and post a minimal example (source code) that demonstrates the problem.

ChrisW67
5th January 2015, 19:37
All the files reporting "errors" are part of a standard, healthy Qt installation. I suggest you reinstall whatever version of Qt you are using, on whatever platform you are on, and do a complete clean build of your project. If it still does not work then follow d_stranz excellent advice and post something useful here.

ChemistBob
10th January 2015, 01:02
All the files reporting "errors" are part of a standard, healthy Qt installation. I suggest you reinstall whatever version of Qt you are using, on whatever platform you are on, and do a complete clean build of your project. If it still does not work then follow d_stranz excellent advice and post something useful here.

thanks!!! let me try again! i no longer have internet on pc! the error appears to when the compiler acces qt header files. every header file segment is the same!! qobject.h line 420 -- qtcreator code: now it's tough using cell phone texting. i have to define some symbols. first underscore // // open paren @/ closing paren /@ the pound sign pd now the code! q// // signal: all caps void destroyed@/qobject astric equal /@ semicolon objectnamechanged@/const qstring &objectname pd if !defined @/q// //qdoc/@ --all caps , qprivatesignal qcap pcap scap pd endif /@ semicolon now the error is qprivate is not defined. so i thougt i'll define it in a header file qprivatesignal.h i tried several versions to avail e.g. void qprivate@/int value/@ any header file that has this if statement generates this error!!

ChrisW67
10th January 2015, 07:20
You can type perfectly good code, complete with capitals, underscores, ampersands, parentheses etc. on a tablet or smart phone. Not that you needed to here... you could just have told us which line of which file in which version of Qt.

For those wondering what the gobbledegook above is:


Q_SIGNALS:
void destroyed(QObject * = 0);
void objectNameChanged(const QString &objectName
#if !defined(Q_QDOC)
, QPrivateSignal
#endif
);

See it in context here: https://qt.gitorious.org/qt/qtbase/source/73a1e8c60d894701f34806cc4b847aa2814bf389:src/corelib/kernel/qobject.h#L416

QPrivateSignal is defined as part of the expansion of the Q_OBJECT macro in QObject derived classes.
https://qt.gitorious.org/qt/qtbase/source/73a1e8c60d894701f34806cc4b847aa2814bf389:src/corelib/kernel/qobjectdefs.h#L150

Did you try this?

I suggest you reinstall whatever version of Qt you are using, on whatever platform you are on, and do a complete clean build of your project.

What version of Qt?
Self-built or a binary distribution? If self-built, what options?
What platform?
What compiler?
What compiler version?
What is a small, self contained bit of code that causes those messages?