def fileSaveDlg(initFilePath='', initFileName='', prompt=_translate('Select file to save'), allowed=None):
 if (allowed is None):
  allowed = 'All files (*.*);;txt (*.txt);;pickled files (*.pickle *.pkl);;shelved files (*.shelf)'
 global qtapp
 qtapp = ensureQtApp()
 fdir = os.path.join(initFilePath, initFileName)
 r = QtWidgets.QFileDialog.getSaveFileName(parent=None, caption=prompt, directory=fdir, filter=allowed)
 return (unicode(r) or None)

def fileSaveDlg ( initFilePath = '' , initFileName = '' , prompt = _translate ( 'Select file to save' ) , allowed = None ) : if ( allowed is None ) : allowed = 'All files (*.*);;txt (*.txt);;pickled files (*.pickle *.pkl);;shelved files (*.shelf)' global qtapp qtapp = ensureQtApp ( ) fdir = os . path . join ( initFilePath , initFileName ) r = QtWidgets . QFileDialog . getSaveFileName ( parent = None , caption = prompt , directory = fdir , filter = allowed ) return ( unicode ( r ) or None )
a simple dialogue allowing write access to the file system .