[GRASS-SVN] r73826 - grass/trunk/gui/wxpython/mapwin
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Dec 24 03:55:29 PST 2018
Author: martinl
Date: 2018-12-24 03:55:29 -0800 (Mon, 24 Dec 2018)
New Revision: 73826
Modified:
grass/trunk/gui/wxpython/mapwin/buffered.py
Log:
wxGUI: only one color (red) for region extent
Modified: grass/trunk/gui/wxpython/mapwin/buffered.py
===================================================================
--- grass/trunk/gui/wxpython/mapwin/buffered.py 2018-12-22 16:55:37 UTC (rev 73825)
+++ grass/trunk/gui/wxpython/mapwin/buffered.py 2018-12-24 11:55:29 UTC (rev 73826)
@@ -1010,16 +1010,7 @@
if self._properties.showRegion:
compReg = self.Map.GetRegion()
dispReg = self.Map.GetCurrentRegion()
- reg = None
- if utils.isInRegion(dispReg, compReg):
- self.polypen = wx.Pen(
- colour=wx.Colour(0, 0, 255, 128),
- width=3, style=wx.SOLID)
- reg = dispReg
- else:
- self.polypen = wx.Pen(colour=wx.Colour(255, 0, 0, 128),
- width=3, style=wx.SOLID)
- reg = compReg
+ reg = dispReg if utils.isInRegion(dispReg, compReg) else compReg
regionCoords = []
regionCoords.append((reg['w'], reg['n']))
@@ -1027,7 +1018,10 @@
regionCoords.append((reg['e'], reg['s']))
regionCoords.append((reg['w'], reg['s']))
regionCoords.append((reg['w'], reg['n']))
+
# draw region extent
+ self.polypen = wx.Pen(colour=wx.Colour(255, 0, 0, 128),
+ width=3, style=wx.SOLID)
self.DrawLines(pdc=self.pdcTransparent, polycoords=regionCoords)
def EraseMap(self):
More information about the grass-commit
mailing list