[GRASS-dev] Some wxPython 3 issues

Anna Petrášová kratochanna at gmail.com
Thu Sep 24 13:39:06 PDT 2015


On Thu, Sep 24, 2015 at 3:31 PM, Markus Neteler <neteler at osgeo.org> wrote:

> On Thu, Sep 24, 2015 at 5:16 PM, Anna Petrášová <kratochanna at gmail.com>
> wrote:
> >
> >
> > On Thu, Sep 24, 2015 at 11:07 AM, Markus Neteler <neteler at osgeo.org>
> wrote:
> >>
> >> On Thu, Sep 24, 2015 at 2:39 PM, Anna Petrášová <kratochanna at gmail.com>
> >> wrote:
> >> >
> >> > please try r66320 in trunk
> >>
> >> Thanks.
> >> I have backported it locally, now I get:
> >>
> >> g.gui.animation strds=raster_aprilie at EUMETSAT
> >> Traceback (most recent call last):
> >>   File "/usr/local/grass-7.0.2svn/scripts/g.gui.animation",
> >> line 136, in <module>
> >>     main()
> >>   File "/usr/local/grass-7.0.2svn/scripts/g.gui.animation",
> >> line 127, in main
> >>     frame = AnimationFrame(parent=None,
> >> giface=StandaloneGrassInterface())
> >>   File
> >> "/usr/local/grass-7.0.2svn/gui/wxpython/animation/frame.py",
> >> line 69, in __init__
> >>     self.animationPanel = AnimationsPanel(self,
> >> self.windows, initialCount=MAX_COUNT)
> >>   File
> >> "/usr/local/grass-7.0.2svn/gui/wxpython/animation/frame.py",
> >> line 330, in __init__
> >>     w = AnimationWindow(self)
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 111, in __init__
> >>     BufferedWindow.__init__(self, parent=parent, id=id,
> >> style=style)
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 49, in __init__
> >>     self.OnSize(None)
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 130, in OnSize
> >>     BufferedWindow.OnSize(self, event)
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 72, in OnSize
> >>     self.UpdateDrawing()
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 93, in UpdateDrawing
> >>     self.Draw(dc)
> >>   File "/usr/local/grass-7.0.2svn/gui/wxpython/animation/map
> >> window.py", line 123, in Draw
> >>     dc.DrawBitmap(self.bitmap, x=self.x, y=self.y)
> >> AttributeError: 'AnimationWindow' object has no attribute
> >> 'x'
> >>
> >
> > That's not surprising, there are changes in trunk. The line should then
> be:
> >
> > dc.DrawBitmap(self.bitmap, x=0, y=0)
>
> I'm afraid to not see the difference. What to change in 7.0?
>

Like that:

-        dc.DrawBitmap(self.bitmap, x=0, y=0)
+        if self.bitmap.IsOk():
+            dc.DrawBitmap(self.bitmap, x=0, y=0)

I don't won't to backport it yet if it's not confirmed it works. I wonder
why can't you test it in trunk?

Anna

>
> >
> >> Markus
> >
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20150924/d1bf8e1d/attachment.html>


More information about the grass-dev mailing list