[wxPython] RE: Which GUI?

Robin Dunn robin at alldunn.com
Thu Feb 17 17:37:46 EST 2000


>
> To get a functional redistributable, you need about 2.7MB of DLLs
> (wx21_13.dll (1.7MB) and wxc.pyd (1.06MB)). This is a considerable memory
> overhead (and loading overhead (my concern), and distribution overhead (not
> something I personally worry about, but apparently some do :) )). Might
> breaking functions into multiple DLLs be a first step in solving the
> problem? I have no idea how hard that would be, but I do wonder how much of
> the 2.7 MB is actually being used by any given wxPython application.

My guess is less than half. I've already disabled a few things in the wx DLL
that I build, but more can be done.  There are a lot of interdependencies
that have to be worked around, but it is doable.  Also, if something is
supported in any of the .pyd's then it needs to be in the wx*.dll, I can't
get around that...

>
> Does swig provide support for creating multiple interface DLLs?  I know
that
> the interface wrappers for HTML, OpenGL etc. are separate, do they all
> interface into the same wxWindows DLL (couldn't find matching wxWindows
DLLs
> for those modules)?

Correct.

> Does wxWindows have options for compiling to multiple
> DLLs?

No.  There is the ability to create a non-gui library, but if using the GUI
classes then it is almost an all or nothing deal.  Parts of wxWindows can be
turned off (essentially just compile to nothing) by setting some #defines in
a header file.  The trouble has been keeping these settings in correlation
with what is in the SWIG interface files, so my approach so far has been to
leave most things turned on.  Now that the newest (alpha) version of SWIG has
a preprocessor that works I plan on using it to process the same header file
and be able to disable the same things in wxPython that are disabled in
wxWindows.  This should significantly help the size issue, and custom
versions can easily be created that strip out all non-essential features.

> Does the delay-loading trick mentioned on the big python list some
> time ago help with the memory and loading overheads?

I havn't tried it yet, but it is on my todo list...

--
Robin Dunn
Software Craftsman
robin at AllDunn.com
http://AllDunn.com/robin/
http://AllDunn.com/wxPython/  Check it out!






More information about the Python-list mailing list