[GRASS-dev] georect.py (bis)

Hello all,

working on grass6.5.0 rev. 36556,

after a bug fix on monday by Martin Landa, once again I have a problem
with georect.py. Same symptoms (display freezing), but this time the
message returned is the following :

        Traceback (most recent call last):
          File "/usr/local/grass-6.5.svn/etc/wxpython/gui_modules/ma
        pdisp_window.py", line 536, in OnIdle
        
        self.UpdateMap(render=True)
          File "/usr/local/grass-6.5.svn/etc/wxpython/gui_modules/ma
        pdisp_window.py", line 725, in UpdateMap
        
        self.parent.GetLayerManager().georectifying.DrawGCP(coordtyp
        e)
          File "/usr/local/grass-6.5.svn/etc/wxpython/gui_modules/ge
        orect.py", line 858, in DrawGCP
        
        wxCol = wx.Colour(col[0], col[1], col[2], 255)
          File "/usr/lib/python2.5/site-
        packages/wx-2.8-gtk2-unicode/wx/_gdi.py", line 114, in
        __init__
        
        _gdi_.Colour_swiginit(self,_gdi_.new_Colour(*args,
        **kwargs))
        TypeError
        :
        in method 'new_Colour', expected argument 1 of type 'byte'
        
Any idea on what is wrong ?

Thank you,
Vincent

Hi,

2009/4/1 Vincent Bain <bain@toraval.fr>:

   wxCol = wx\.Colour\(col\[0\], col\[1\], col\[2\], 255\)

put before this line

print col

?

M.

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Then it returns :

(0, 0, 255, 255)

Thanks,
Vincent

Le mercredi 01 avril 2009 à 19:26 +0200, Martin Landa a écrit :

Hi,

2009/4/1 Vincent Bain <bain@toraval.fr>:

> wxCol = wx.Colour(col[0], col[1], col[2], 255)

put before this line

print col

?

M.

2009/4/1 Vincent Bain <bain@toraval.fr>:

Then it returns :

(0, 0, 255, 255)

hm, version of Python and wxPython?

M.

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

2009/4/1 Martin Landa <landa.martin@gmail.com>:

2009/4/1 Vincent Bain <bain@toraval.fr>:

Then it returns :

(0, 0, 255, 255)

hm, version of Python and wxPython?

please check also type of col[0], e.g.

print type(col[0])

it should be 'int'.

M.

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Returns :

(0, 0, 255, 255)
<type 'str'>

python --version
Python 2.5.2

wx-config --version
2.8.7

VB

Le mercredi 01 avril 2009 à 20:00 +0200, Martin Landa a écrit :

M.