Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.
Hi, I'm having this problem.
I have installed wxPyPlot as plugin, the icon of wxPyPlot appears under USER Tab, when I click on it and then on a frame into the FRAME DESIGNER all is OK, the code is generated and the aplication runs well. Then when I try to edit something and click on de Frame Designer button this error is showed.
"Views.InspectableViews.Desiner Error: wxPyPlot.WxPyPlot.plotCanvas is not defined on the Pallete"
and the Frame Designer doesn't open.
Thanks in advance.
PD. I'm using Python 2.4
Werner F. Bruhin
I can't recreate this problem.
What version of wxPython and Boa are you using?
You might be using an older version of Boa, as in mine wxPyPlot shows up in LIB tab and not USER tab.
Thanks for answer, I'm using wx 2.6 and Boa 0.4.4
Did you install wxPyPlot or it came with the Boa instalation?
Werner F. Bruhin
I did not install anything to use wxPyPlot. I believe it is part of the standard wx install and the Boa plug-in comes standard with Boa.
The test I did on Python 2.5 final, wxPython 2.7 (latest preview 20061006) and a relatively recent CVS download of Boa 0.4.4 (about 3 or 4 weeks ago).
Maybe try a CVS refresh of Boa?
You are right Boa comes with wx.lib.plot.plotcanvas.py and its plugin script.
The wxPyPlot that I have installed is older (2003) than the Boa ones. So I have uninstalled the old plugin and reinstalled the one which comes with Boa and now PlotCanvas appears under Library tab. But (there is always a but...) when traying to put it into a Frame this error is showed.
- Type Error:_init_()Got an unexpected keyword argument 'style' -
Werner F. Bruhin
Yes I did see this error on my second copy of Boa which is an older CVS checkout (at least 6 month).
When did you get your copy of Boa? If it is pretty old I would suggest getting a newer copy, also you might have to checkout with a date October 8, 2006 as I have seen that Riaan has started a check-in yesterday.
If your copy of Boa is recent, let me know and I will try to track the problem down.
I mentioned this to Riaan and he said that there is an issue with plot.py in wxPython 2.6 which is fixed in wxPython 2.7.
Comparing the two I found if I change around line 466 in the 2.6 version to match what is in 2.7 then it works fine.
The change is:
def __init__(self, parent, id=wx.ID_ANY, pos=wx.DefaultPosition,
size=wx.DefaultSize, style=0, name="plotCanvas"):
"""Constructs a panel, which can be a child of a frame or
any other non-control window"""
wx.Panel.__init__(self, parent, id, pos, size, style, name)
Hope this helps
I have downloaded and installed Boa on 09/2006.
I made the changes you proposed and things goes diferent now. No error is showed but it is still with problems, now I can click the icon and drag de control on a Frame, it appears with size(20,20), so I enlarge it to something like size(150,140) and the code generated is OK, whe I reopen the Designer, PlotCanvas resets itself to the original size(20,20). Another thing happening is that it do not recive focus when I click on it, so I must select it trough the Object Instector Tab
This is a Challenge!!!