248 self.trUtf8("Select data file"), |
248 self.trUtf8("Select data file"), |
249 self.workingDir, |
249 self.workingDir, |
250 self.fileFilters, |
250 self.fileFilters, |
251 None) |
251 None) |
252 |
252 |
253 if not fname.isEmpty(): |
253 if fname: |
254 ext = QFileInfo(fname).suffix() |
254 ext = QFileInfo(fname).suffix() |
255 if ext.isEmpty(): |
255 if not ext: |
256 ex = selectedFilter.section('(*', 1, 1).section(')', 0, 0) |
256 ex = selectedFilter.split("(*")[1].split(")")[0] |
257 if not ex.isEmpty(): |
257 if ex: |
258 fname.append(ex) |
258 fname += ex |
259 |
259 |
260 txt = self.resultbox.toPlainText() |
260 txt = self.resultbox.toPlainText() |
261 |
261 |
262 try: |
262 try: |
263 f = open(fname, "w", encoding="utf-8") |
263 f = open(fname, "w", encoding="utf-8") |