From kde-devel Mon Apr 18 23:36:33 2005 From: Andreas Pakulat Date: Mon, 18 Apr 2005 23:36:33 +0000 To: kde-devel Subject: linkage error with ui-based classes Message-Id: <20050418233633.GA25937 () morpheus ! apaku ! dnsalias ! org> X-MARC-Message: https://marc.info/?l=kde-devel&m=111386744613614 Hi, I got back to my project today (in the meantime I switched to kde3.4 and kdevelop cvs, but I don't think its related to my problem). I made a dialog as .ui-file and then created a c++-class, which is using the .ui as baseclass. Now when instantiating this c++-class I get the following linkage error: imageprepareview.o(.text+0x22d6): In function `ImagePrepareView::slotShowDocSettings()': /home/andreas/projects/imageprepare/src/imageprepareview.cpp:321: undefined reference to `ImagePrepareDocSettings::ImagePrepareDocSettings[in-charge](QWidget*, char const*, bool, unsigned)' The header file of ImagePrepareDocSettings is included in this cpp-file and the constructor is defined aproprately: class ImagePrepareDocSettings : public ImagePrepareDocSettingsBase { Q_OBJECT public: ImagePrepareDocSettings(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 ); .. } The function slotShowDocSettings() looks like this: void ImagePrepareView::slotShowDocSettings() { ImagePrepareDocSettings* sett = new ImagePrepareDocSettings(this); sett->show(); } I tried to google for that, but the answers did not work or where not applicable (having a forward declaration within a class instead of global scope, or just reordering the files in the Makefile.am) Anybody got any hints on this? Andreas -- You will gain money by an immoral action. >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<