svghmi/svghmi.py
branchsvghmi
changeset 3158 4171f7dd109a
parent 3140 cae53fe54cf2
child 3159 1d7c3d13a4df
--- a/svghmi/svghmi.py	Fri Feb 19 12:02:49 2021 +0100
+++ b/svghmi/svghmi.py	Fri Feb 19 12:03:42 2021 +0100
@@ -705,13 +705,16 @@
                 else:
                     self.GetCTRoot().logger.write_error(_("PO file misplaced: %s is not in %s\n") % (POFile,project_path))
             else:
-                self.GetCTRoot().logger.write_error(_("PO file do not exist: %s\n") % POFile)
+                self.GetCTRoot().logger.write_error(_("PO file does not exist: %s\n") % POFile)
         dialog.Destroy()
 
     def _OpenPOT(self):
         """ Start POEdit with untouched empty catalog """
         POFile = self._getPOTpath()
-        self._StartPOEdit(POFile)
+        if os.path.isfile(POFile):
+            self._StartPOEdit(POFile)
+        else:
+            self.GetCTRoot().logger.write_error(_("POT file does not exist, add translatable text (label starting with '_') in Inkscape first\n"))
 
     def CTNGlobalInstances(self):
         # view_name = self.BaseParams.getName()