浏览代码

wxGUI/composer: catch error due to Ghostscript missing or not on path

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@64991 15284696-431f-4ddb-bdfa-cd5b030d7da7
Anna Petrášová 10 年之前
父节点
当前提交
634d78bc1c
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      gui/wxpython/psmap/frame.py

+ 2 - 2
gui/wxpython/psmap/frame.py

@@ -350,10 +350,10 @@ class PsMapFrame(wx.Frame):
                     import types
                     im.load = types.MethodType(loadPSForWindows, im)
                 im.save(self.imgName, format = 'PNG')
-            except IOError as e:
+            except (IOError, OSError) as e:
                 del busy
                 dlg = HyperlinkDialog(self, title=_("Preview not available"),
-                                      message=_("Preview is not available probably due to missing Ghostscript."),
+                                      message=_("Preview is not available probably because Ghostscript is not installed or not on PATH."),
                                       hyperlink='http://trac.osgeo.org/grass/wiki/CompileOnWindows#Ghostscript',
                                       hyperlinkLabel=_("Please follow instructions on GRASS Trac Wiki."))
                 dlg.ShowModal()