Re: wxEuphoria

new topic     » goto parent     » topic index » view thread      » older message » newer message

On Thu, Feb 13, 2003 at 10:33:25AM -0500, Matthew Lewis wrote:
> I forgot to mention that you'll want to turn threading off.  Look in
> setup.h.  I got errors when I compiled with threads.
> Change:
> #define wxUSE_THREADS 1
> to
> #define wxUSE_THREADS 0
> (or just comment out, I can't remember exactly how I did it)
> 

Oh. Well, if I get errors I'll do it that way as well ... I'm using wxX11 with
wxUniversal. (I'm thinking I might have wanted the wxGTK one instead tho.)
For now, I'm gonna wait for the compile to actually FINISH. (Been going on for
a few day now. :[ )

> Here's how I'm planning to separate Windows and Linux code.  First, I plan
> to group related classes together in their own include files, and to make
> them modular.  For instance, wxFrame and wxWindow will be in wxWindow.e.
> But there will be two additional include files for each .e file: a .ew and
> .eu.  The user will actually include the .ew/.ew files, so only the platform

I assume you meant ".ew/.eu" not ".ew/.ew"

> independant code can be put into the .e files.  All the import data is
> stored in the .ew file, so we won't have to worry about a 1meg include file
> for Hello World.  I've also put a _Platform constant in each .ew file so
> that it's possible to automatically identify when someone accidentally mixes
> windows and linux include files.
> 
> I've only done this conversion for wxWindow and wxFrame so far, but here's
> what the beginning of wxFractal.exw now looks like:
> 
> -- wxFractal.exw
> -- Matt Lewis
> 
> without warning
> include wxEuphoria.ew
> include wxWindow.ew
> include wxMenu.e
> include wxGraphics.e
> 
> object void
> 
> constant
> frame = create( wxFrame, {0, -1, "Fractal Mountains for wxWindows", -1, -1,
> 640, 480} ),
> canvas = create( wxWindow, {frame}),
> 
> menu = new_wxMenu( ),
> menu_bar = new_wxMenuBar(),
> 
> -- end sample
> 
> It's a lot clearer, and the program flow is just like that of a win32lib
> app.
> 
> Matt Lewis
>  

Yes. Sounds like a good idea to me.

As for the possibility of classes being dependant on platform, I'd doubt it,
in any case I'm using wxX11 (which provides only the most low-level primitives
needed, such as windows and graphics drawing) with wxUniversal (which emulates
all controls with the low-level drawing primitives from another wxWindows
library). Hence, if classes are platform-dependant, then I'll have the lowest
common denominator lib.
(Obviously, wxX11 needs wxUniversal, since raw Xlib provides no widgets at all,
however wxGTK and wxMSW can be compiled with wxUniversal iirc.)

jbrown

> 
> 
> 
> TOPICA - Start your own email discussion group. FREE!

-- 
 /"\  ASCII ribbon              | http://www.geocities.com/jbrown1050/
 \ /  campain against           | Linux User:190064
  X   HTML in e-mail and        | Linux Machine:84163
 /*\  news, and unneeded MIME   |

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu