QT 文件知识

来源:互联网 发布:http代理服务器软件 编辑:程序博客网 时间:2024/05/16 04:56

打开文件及过滤文件后缀:

QString fileName = QFileDialog::getOpenFileName(this, //当前tr("Open File"),//标题                                                "/home",//起始路径 QDir::currentPath() 程序当前路径                                                tr("Images (*.png *.xpm *.jpg)")//过滤);   //多文件过滤:   QString path = QFileDialog::getOpenFileName(this,"Select File","/home","txt(*.txt);;image(*.jpg)");


0 0
原创粉丝点击