Code: Alles auswählen
#include <qapplication.h>
#include <qpushbutton.h>
int main( int argc, char **argv )
{
QApplication a( argc, argv );
QPushButton hello( "Hello world!", 0 );
hello.resize( 100, 30 );
a.setMainWidget( &hello );
hello.show();
return a.exec();
}
Damit läuft nicht ein einziges Beispiel aus dem Tutorial - was mache ich also falsch ? Oder ist der Code nicht mehr für Version 4.x geeignet ?.\main.cpp(8) : error C2039: 'setMainWidget': Ist kein Element von 'QApplication'
Matthias