Events in console application

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
Post Reply
KaReL
Experienced Solver
Experienced Solver
Posts: 78
Joined: Mon Aug 30, 2004 8:52 am
Contact:

Events in console application

Post by KaReL » Sun Nov 06, 2005 8:15 am

Hi,

First things first... What I want to achieve is a multithreaded server which does a lot of things on unix/windows/mac without showing any frames.

That brings me to my question:
Is it possible to use events in console applications? (The answer would be no, I guess).
So the second thing to ask is: what can I do if all I need is a wxLoadLibrary, wxThread and wxSocketServer/Client?

Under windows it's perfectly possible to start a program, but just hides all the frames and stuff so it looks like a non-gui application.

Is the same possible on Linux/mac so you can compile the wx library and starting a program just from /etc/init.d at boot time?


Thanks!
Steven
wxWidgets: SVN/trunk
OS: WinXP/2 + Ubuntu + Mac 10.4.11
Compiler: VS2005 + GCC 4.2 + GCC 4.0.1
-----
home: http://www.salvania.be

j_pilborough
Knows some wx things
Knows some wx things
Posts: 27
Joined: Thu May 26, 2005 10:39 am
Contact:

Post by j_pilborough » Wed Nov 09, 2005 11:21 am

You need to check if these classes need wxCore or not. wxCore should not be used for console-mode apps.

leio
Can't get richer than this
Can't get richer than this
Posts: 802
Joined: Mon Dec 27, 2004 10:46 am
Location: Estonia, Tallinn
Contact:

Post by leio » Wed Nov 09, 2005 4:41 pm

wxEvents require wxCore and the main loop to function currently. There is effort going on to make it available for wxBase, but that's initial private work on top of CVS HEAD, I believe. Can't remember who was working on it, wx-dev ml has the info.
Compilers: gcc-3.3.6, gcc-3.4.5, gcc-4.0.2, gcc-4.1.0 and MSVC6
OS's: Gentoo Linux, WinXP; WX: CVS HEAD

Project Manager of wxMUD - http://wxmud.sf.net/
Developer of wxGTK;
gtk+ port maintainer of OMGUI - http://www.omgui.org/

kweinert
In need of some credit
In need of some credit
Posts: 4
Joined: Wed Jun 07, 2006 3:04 am
Location: Westminster, CO, USA
Contact:

Post by kweinert » Wed Jun 07, 2006 3:19 am

Is this still true?

Lacking this, can I create a wxApp based application and just never show the form? Will events and such still work in this case?

Thanks for any info.
Ken Weinert
http://galaxyweb.quarter-flash.com
Trying to learn to be more XPish

Post Reply