From where do we download version 2.3.3 ?
···
------------------------------------------------------------------------------------
From Robin Dunn:
drawlist = [(0,0),(100,0),(100,100),(0,100)]
region = wxRegion(4,drawlist,wxODDEVEN_RULE)
> if region.Contains(event.GetPosition()) == wxInRegion:
Results in:
Traceback (most recent call last):
File "testDwgInput.py", line 207, in onMouseEvents
region = wxRegion(4,drawlist,wxODDEVEN_RULE)
File "C:\Python22\lib\site-packages\wxPython\gdi.py", line 1237, in __init__
self.this = apply(gdic.new_wxRegion,_args,_kwargs)
TypeError: an integer is required
Currently only the (x,y,width,height) wxRegion constructor is wrapped in wxPython but I've added wxRegionFromPoints for 2.3.3. You'll be able to use it like this: region = wxRegionFromPoints(drawlist)
-- Robin Dunn Software Craftsman <http://wxPython.org> Java give you jitters? Relax with wxPython!