瀏覽代碼

Add comments for translators and fix gettext usage

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@67648 15284696-431f-4ddb-bdfa-cd5b030d7da7
Maris Nartiss 9 年之前
父節點
當前提交
1652517a3e
共有 3 個文件被更改,包括 8 次插入4 次删除
  1. 2 0
      gui/wxpython/psmap/dialogs.py
  2. 5 3
      lib/init/grass.py
  3. 1 1
      lib/vector/diglib/struct_alloc.c

+ 2 - 0
gui/wxpython/psmap/dialogs.py

@@ -760,6 +760,7 @@ class MapFramePanel(wx.Panel):
         border.Add(item = sizer, proportion = 0, flag = wx.ALL | wx.EXPAND, border = 5)
         border.Add(item = sizer, proportion = 0, flag = wx.ALL | wx.EXPAND, border = 5)
         
         
         # border
         # border
+        # GTC Line around legend or map frame
         box   = wx.StaticBox (parent = self, id = wx.ID_ANY, label = " %s " % _("Border"))        
         box   = wx.StaticBox (parent = self, id = wx.ID_ANY, label = " %s " % _("Border"))        
         sizer = wx.StaticBoxSizer(box, wx.HORIZONTAL)
         sizer = wx.StaticBoxSizer(box, wx.HORIZONTAL)
         gridBagSizer = wx.GridBagSizer(hgap = 5, vgap = 5)
         gridBagSizer = wx.GridBagSizer(hgap = 5, vgap = 5)
@@ -2644,6 +2645,7 @@ class LegendDialog(PsmapDialog):
         self.sizePositionFont(legendType = 'vector', parent = panel, mainSizer = border)
         self.sizePositionFont(legendType = 'vector', parent = panel, mainSizer = border)
          
          
         # border
         # border
+        # GTC  Line around legend or map frame
         box   = wx.StaticBox (parent = panel, id = wx.ID_ANY, label = " %s " % _("Border"))
         box   = wx.StaticBox (parent = panel, id = wx.ID_ANY, label = " %s " % _("Border"))
         sizer = wx.StaticBoxSizer(box, wx.VERTICAL)
         sizer = wx.StaticBoxSizer(box, wx.VERTICAL)
         flexGridSizer = wx.FlexGridSizer(cols = 2, hgap = 5, vgap = 5)
         flexGridSizer = wx.FlexGridSizer(cols = 2, hgap = 5, vgap = 5)

+ 5 - 3
lib/init/grass.py

@@ -1169,12 +1169,13 @@ def lock_mapset(mapset_path, force_gislock_removal, user, grass_gui):
     if not os.path.exists(mapset_path):
     if not os.path.exists(mapset_path):
         fatal(_("Path '%s' doesn't exist") % mapset_path)
         fatal(_("Path '%s' doesn't exist") % mapset_path)
     if not os.access(mapset_path, os.W_OK):
     if not os.access(mapset_path, os.W_OK):
-        error = "Path '%s' not accessible.\n" % mapset_path
+        error = _("Path '%s' not accessible.") % mapset_path
         stat_info = os.stat(mapset_path)
         stat_info = os.stat(mapset_path)
         mapset_uid = stat_info.st_uid
         mapset_uid = stat_info.st_uid
         if mapset_uid != os.getuid():
         if mapset_uid != os.getuid():
-            error += "You are not the owner of '%s'" % mapset_path
-        fatal(_(error))
+            # GTC %s is mapset's folder path
+            error = "%s\n%s" % (error, _("You are not the owner of '%s'.") % mapset_path)
+        fatal(error)
     # Check for concurrent use
     # Check for concurrent use
     lockfile = os.path.join(mapset_path, ".gislock")
     lockfile = os.path.join(mapset_path, ".gislock")
     ret = call([gpath("etc", "lock"), lockfile, "%d" % os.getpid()])
     ret = call([gpath("etc", "lock"), lockfile, "%d" % os.getpid()])
@@ -1416,6 +1417,7 @@ r"""
 %-41sg.manual -i
 %-41sg.manual -i
 %-41sg.version -c
 %-41sg.version -c
 """ % (_("GRASS GIS homepage:"),
 """ % (_("GRASS GIS homepage:"),
+        # GTC Running through: SHELL NAME
        _("This version running through:"),
        _("This version running through:"),
        shellname, os.getenv('SHELL'),
        shellname, os.getenv('SHELL'),
        _("Help is available with the command:"),
        _("Help is available with the command:"),

+ 1 - 1
lib/vector/diglib/struct_alloc.c

@@ -488,6 +488,6 @@ int dig_isle_alloc_line(struct P_isle * isle, int add)
 */
 */
 int dig_out_of_memory()
 int dig_out_of_memory()
 {
 {
-    G_warning(_("Out of memmory"));
+    G_warning(_("Out of memory"));
     return -1;
     return -1;
 }
 }