Details
-
Bug
-
Resolution: Cannot Reproduce
-
Not Evaluated
-
None
-
Qt Creator 3.1.0
-
None
-
Windows, Linux
Description
Default:
namespace Ui {
class MyClass : public QWidget {
Ui:MyClass *ui;
}
This works with Designer. Designer can find the ui file and use slots to implement code in myClass.cpp
How ever this do not work:
namespace MyName {
class MyClass : public QWidget {
Ui::MyClass *ui;
}
And this does not work:
namespace MyName {
class MyClass : public QWidget {
MyName::MyClass *ui;
}
Both these examples makes ui files not work anymore for slot mechanism.
Til esample I have program that uses several namespaces:
namespace MyApp {
namespace MyCore {
namespace MyGuis {
class MyClass : public QWidget {
Ui::MyClass *ui;
}
}
}
}
And this does not work. The Ui file exepcts to belong in namespace Ui and when defining other namespaces where the ui is produced the compiler cannot work because Ui does not name type. Qt Creator should add code to handle different name spaces when finding a ui class where to add slot.