Using maskededit controls with xrc and wxpython

D

Dave Williams

Hi,
I'm having problems getting IpAddrCtrl working with a frame containing
nested sizers generated from an xrc file.

Firstly I tried adding it using AttachUnknownControl as per the
example code Using XMLResources on the wxPython wiki. This renders but
does not size correctly despite my trying many different variations.
Because of my nested sizers I also seem to have to SetSizeHints etc at
a higher level than in the example. Also I note that some of the
functions used are marked in the wxWidgets docs as "for internal use
only".

Secondly I tried using subclassing as per the XMLResource*.py demos in
the wxWigets/wxPython. This has the problem that it uses 2 stage
creation which IPAddrCtrl etc doesnt support out of the box (yet?). As
a Python newbie I'm still finding my way around so dont know how
difficult that is to implement.

I also note that XmlSubclassFactory_Python in wx/xrc.py will only
instantiate a control using klass = getattr(module, cname) then
klass() which does not allow for any parameter passing at that stage.

Can anyone point me in the right direction? I need to get forward with
my overall development and can't afford to get stuck on something that
admittedly I had hoped would be "routine" to implement.
Thanks
Dave
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top