[PyQt] pyqt4.10.4 QtGui.QFileDialog.getOpenFileNames can not work well with Anaconda1.9r

Phil Thompson phil at riverbankcomputing.com
Tue Apr 29 10:48:00 BST 2014


On 29/04/2014 10:28 am, shaohua199 wrote:
> Hi,
> 
> After I install the pyqt4.10.4 into the Anaconda1.9.2(python2.7.6),
> and run the following test script:
> 
> import sys
> import os
> from PyQt4 import QtGui
> if __name__ == "__main__":
>  app = QtGui.QApplication(sys.argv)
> 
>  filter_ = "Library File(*.lib *.l *.scs);;All File(*.*)"
>  title = "Select files"
>  lib_path_list = QtGui.QFileDialog.getOpenFileNames(None, title,
> os.getcwd(), filter_)
> 
>  sys.exit(app.exec_())
> 
> Then, the dialog show, but can not display the file name, directory
> name normally, just like following picture:
> 
> Could you tell me what reason it is, how can I fix this issue?
> Thank you very much!!

Most likely a problem with your Qt installation, or Anaconda. Nothing to 
do with PyQt.

Phil


More information about the PyQt mailing list