For some reasons, QPushButton shows up differently even though the code is mostly the same. Has anyone experienced the same issue and possibly have fixed it??
Here are the details:
btnQuit.resize(75, 30);
QObject::connect(&btnQuit,
SIGNAL(clicked
()),
&app,
SLOT(quit
()));
btnQuit.show();
return app.exec();
QApplication app(argc, argv);
QPushButton btnQuit("Exit");
btnQuit.resize(75, 30);
btnQuit.setFont(QFont("Times", 18, QFont::Bold));
QObject::connect(&btnQuit, SIGNAL(clicked()), &app, SLOT(quit()));
btnQuit.show();
return app.exec();
To copy to clipboard, switch view to plain text mode
results in:

wnd.resize(200, 120);
btnQuit.resize(75, 30);
btnQuit.setGeometry(10, 40, 180, 40);
QObject::connect(&btnQuit,
SIGNAL(clicked
()),
&appl,
SLOT(quit
()));
wnd.show();
return appl.exec();
QApplication appl(argc, argv);
QWidget wnd;
wnd.resize(200, 120);
QPushButton btnQuit("Exit", &wnd);
btnQuit.resize(75, 30);
btnQuit.setFont(QFont("Times", 18, QFont::Bold));
btnQuit.setGeometry(10, 40, 180, 40);
QObject::connect(&btnQuit, SIGNAL(clicked()), &appl, SLOT(quit()));
wnd.show();
return appl.exec();
To copy to clipboard, switch view to plain text mode
results in:
Bookmarks