C:/Qt/examples/tools/regexp 1. 如果除了程序所在路径,我们还想要程序的完整名称。那么可以这么写: qApp->applicationFilePath() 1. 还是上面的例子,结果是: C:/Qt/examples/tools/regexp/regexp.exe 1. 当前工作目录 QDir 提供了一个静态函数 currentPath() 可以获取当前工作目录,函数原型如下: QStringQDir...
C:/Qt/examples/tools/regexp 1. 如果除了程序所在路径,我们还想要程序的完整名称。那么可以这么写: qApp->applicationFilePath() 1. 还是上面的例子,结果是: C:/Qt/examples/tools/regexp/regexp.exe 1. 当前工作目录 QDir 提供了一个静态函数 currentPath() 可以获取当前工作目录,函数原型如下: QString QD...
C:/Qt/examples/tools/regexp 1. 如果除了程序所在路径,我们还想要程序的完整名称。那么可以这么写: qApp->applicationFilePath() 1. 还是上面的例子,结果是: C:/Qt/examples/tools/regexp/regexp.exe 1. 当前工作目录 QDir 提供了一个静态函数 currentPath() 可以获取当前工作目录,函数原型如下: QString QD...