且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何将整个目录添加到 QT Creator 项目中

更新时间:2023-02-17 07:49:27

最简单的方法是直接编辑你的.pro文件,添加HEADERS += mydir/*.hSOURCES+= mydir/*.cpp 并且整个目录的内容将显示在 QT Creator 中.进一步参考:http://qt-project.org/doc/qt-5/qmake-project-files.html

The simplest way is to directly edit your .pro file, add HEADERS += mydir/*.h and SOURCES += mydir/*.cpp and the contents of the whole directory will show up in QT Creator. Further reference: http://qt-project.org/doc/qt-5/qmake-project-files.html