1
0
mirror of https://gitee.com/drabel/LibQQt.git synced 2025-01-04 10:18:44 +08:00

26 lines
604 B
C++
Raw Normal View History

#include "mainwindow.h"
#include <QApplication>
2017-11-23 12:33:32 +08:00
#include "qqtobjectfactory.h"
#include "qqtcore.h"
int main ( int argc, char* argv[] )
{
2017-11-23 12:33:32 +08:00
QApplication a ( argc, argv );
QQtWidgetFactory::registerObject<QPushButton>();
QObject* obj = QQtWidgetFactory::createObject ( "QPushButton" );
pline() << obj->inherits ( "QWidget" );
pline() << obj->inherits ( "QPushButton" );
pline() << obj->inherits ( "QObject" );
obj->setObjectName ( "bbb" );
pline() << obj->objectName();
QQtObjectParcel::registerObject ( obj );
MainWindow w;
w.show();
return a.exec();
}