QtWidgets and QWidget
What's the difference between #include<QtWidgets > and #include<QWidget>
I search the qt document but i can't figure out.
Read here: http://doc.qt.io/qt-5/qtwidgets-index.html
QtWidgets is a module containing all Qt widgets. QWidget is a widget class. You should not include whole modules, instead include only header files containing classes you really use. For example if you need QWidget then include QWidget, if you need QPushButton then include QPushButton.