[Gtkradiant] synapse has landed

Timothee Besset gtkradiant@zerowing.idsoftware.com
Mon, 04 Mar 2002 16:50:23 +0100

Ok, synapse has been merged in to the trunk. In short it's a general and 
easier way to do plugins/modules. A sort of COM light, client server 
oriented. The modules have been converted to use synapse, as well as 
textool. The other plugins will be converted too.

The old plugin/module code is still in for some parts, but mostly disabled 
and will be cleaned up when we get everything straightened up.

Here's how to proceed when converting a plugin or a module to synapse:

- have a look at 
this is synapse's design document. It will tell you a few things on how it 
works, and how it was designed. The basics for usage are that it's a static 
lib that provides client or server functionality, depending what you want 
to do.

- look more closely at the implementation, through doxygen:
is a good start point

- now to the actual convert. if it's a plugin, you should cut and paste 
stuff from textool, if it's a module, from vfspk3
	- edit the main header to #include "synapse.h", and declare your custom 
synapse client (see textool's CSynapseClientTexTool 
	- in the main implementation, copy and adapt the client implementation 
from TexTool to your own thing. Mostly, you need to customize the about 
message, and to list properly the SYN_REQUIRE / SYN_PROVIDE stuff
	- you can now comment out the old exported functions (QERPlug_Init, 
QERPlug_Dispatch etc.)
	- on Linux, update the Conscript to link against synapse, to include 
STLPort etc.
	- on win32, update the .dsp to depend on synapse, add the include paths to 
STLPort, and edit the .def (the only exported function being 
Synapse_Enumerate now)
	- try to load it up, log the console to a file and examine it for 
debugging .. post on the list if you have trouble ..