#2315 closed enhancement (fixed)
wxGUI mapswipe: icon AddLayerRGB wish
Reported by: | neteler | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.0.0 |
Component: | wxGUI | Version: | svn-releasebranch70 |
Keywords: | mapswipe | Cc: | |
CPU: | Unspecified | Platform: | Unspecified |
Description
It would be very useful to have RGB layer support in mapswipe since it is often used for multispectral data visualization.
There might be some potentially re-usable code in iclass:
wxpython/iclass/frame.py def AddLayerRGB(self, cmd): ... wxpython/iclass/toolbars.py def OnAddRGB(self, event): ...
Change History (14)
follow-up: 2 comment:1 by , 11 years ago
follow-up: 3 comment:2 by , 11 years ago
Thanks - I tried r60594, switching to 'advanced mode' but somehow the new addRGB icon does now show up...
comment:3 by , 11 years ago
follow-up: 5 comment:4 by , 11 years ago
Now the icon is there and the RGB channels can be loaded. Only this issue happens when adding as second map a "normal" raster map:
GRASS 7.1.svn (nc_spm_08_grass7):~ > g.gui.mapswipe GRASS 7.1.svn (nc_spm_08_grass7):~ > Traceback (most recent call last): File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/forms.py", line 662, in OnOK cmd = self.OnApply(event) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/forms.py", line 677, in OnApply self) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/simplelmgr.py", line 333, in GetOptData self._update() File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/simplelmgr.py", line 301, in _update self._checkList.SetItems(items) File "/usr/lib64/python2.7/site-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 11984, in SetItems self.AppendItems(items) File "/usr/lib64/python2.7/site-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 11846, in AppendItems return _core_.ItemContainer_AppendItems(*args, **kwargs) TypeError: String or Unicode type required
comment:5 by , 11 years ago
Replying to neteler:
Now the icon is there and the RGB channels can be loaded. Only this issue happens when adding as second map a "normal" raster map:
GRASS 7.1.svn (nc_spm_08_grass7):~ > g.gui.mapswipe GRASS 7.1.svn (nc_spm_08_grass7):~ > Traceback (most recent call last): return _core_.ItemContainer_AppendItems(*args, **kwargs) TypeError: String or Unicode type required
Could you try it again? Similar things happen to me but only sometimes and I was not able to reproduce it.
follow-up: 7 comment:6 by , 11 years ago
Tried again: I open g.gui.mapswipe, switch to "Advanced mode", then bacl to "Simple mode" and
GRASS 7.1.svn (nc_spm_08_grass7):~ > Traceback (most recent call last): File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapswipe/dialogs.py", line 176, in OnSwitchMode self._switchMode(simple=True) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapswipe/dialogs.py", line 172, in _switchMode self.applyChanges.emit() File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/etc/python/grass/pydispatch/signal.py", line 229, in emit dispatcher.send(signal=self, *args, **kwargs) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/etc/python/grass/pydispatch/dispatcher.py", line 343, in send **named File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/etc/python/grass/pydispatch/robustapply.py", line 57, in robustApply return receiver(*arguments, **named) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapswipe/frame.py", line 401, in OnApplyInputChanges self.ZoomToMap() File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapswipe/frame.py", line 337, in ZoomToMap self.GetFirstWindow().ZoomToMap(layers = layers) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapwin/buffered.py", line 1742, in ZoomToMap layers = self._giface.GetLayerList().GetSelectedLayers(checkedOnly=False) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/core/giface.py", line 257, in GetLayerList raise NotImplementedError() NotImplementedError
Still the windows are existing. Then I go back to "Advanced", select RGB, when closing that dialog I get
Traceback (most recent call last): File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/forms.py", line 662, in OnOK cmd = self.OnApply(event) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/forms.py", line 677, in OnApply self) File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/simplelmgr.py", line 333, in GetOptData self._update() File "/home/neteler/software/grass71/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/simplelmgr.py", line 301, in _update self._checkList.SetItems(items) File "/usr/lib64/python2.7/site-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 11984, in SetItems self.AppendItems(items) File "/usr/lib64/python2.7/site-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 11846, in AppendItems return _core_.ItemContainer_AppendItems(*args, **kwargs) TypeError: String or Unicode type required
Some initialization issue is still there...
follow-up: 8 comment:7 by , 11 years ago
Replying to neteler:
Tried again: I open g.gui.mapswipe, switch to "Advanced mode", then bacl to "Simple mode" and
that's not related, I will look at it later
Still the windows are existing. Then I go back to "Advanced", select RGB, when closing that dialog I get
Traceback (most recent call last): return _core_.ItemContainer_AppendItems(*args, **kwargs) TypeError: String or Unicode type required
Some initialization issue is still there...
I am still not able to reproduce it, I got it once from something like 7 attempts.
follow-up: 9 comment:8 by , 11 years ago
Replying to annakrat:
Replying to neteler:
Traceback (most recent call last): return _core_.ItemContainer_AppendItems(*args, **kwargs) TypeError: String or Unicode type requiredSome initialization issue is still there...
I am still not able to reproduce it, I got it once from something like 7 attempts.
Please try r60753. It is supposed to fix the string or Unicode type required error. Do we want this new feature in beta3?
follow-up: 10 comment:9 by , 11 years ago
comment:10 by , 11 years ago
Replying to neteler:
Replying to annakrat: ...
Please try r60753. It is supposed to fix the string or Unicode type required error.
Excellent, seems to be solved.
Do we want this new feature in beta3?
For users very important, so I would say yes. It does not look too invasive and we are pre-feature freeze here.
Backported in r60756. The other error should be fixed in 60757 (and already backported).
comment:11 by , 10 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Thanks for the enhancement. Closing.
Please try 60594. It's available in the 'advanced mode'.