浏览代码

g.gui.tplot: resolved problem with stdvs when no categories are set, see https://trac.osgeo.org/grass/ticket/3294

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@72485 15284696-431f-4ddb-bdfa-cd5b030d7da7
Luca Delucchi 7 年之前
父节点
当前提交
3513d7dcf8
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      gui/wxpython/tplot/frame.py

+ 2 - 0
gui/wxpython/tplot/frame.py

@@ -381,6 +381,8 @@ class TplotFrame(wx.Frame):
         """Get a list of categories for a vector map"""
         vdb = grass.read_command('v.category', input=mapp, option='print')
         categories = vdb.splitlines()
+        if not cats:
+            return categories
         for cat in cats:
             if str(cat) not in categories:
                 GMessage(message=_("Category {ca} is not on vector map"