[fpc-devel] Threads and alot of crap continued

Daniël Mantione daniel.mantione at freepascal.org
Thu Nov 9 20:51:58 CET 2006

Op Thu, 9 Nov 2006, schreef Florian Klaempfl:

> Michael Schnell schrieb:
> > BTW.:
> > 
> > TPC comes with Free Vision.
> > 
> > The FPC IDE based on Free Vision seems to work fine.
> > 
> > The Free Vision "Non-GUI" seems to be event driven and thus needs to
> > implement a kind of event scheduler.
> It's an event handling loop using queues for input events. Very primitive :)

Hmmm... Actually I think event handling mechanism in FV is quite advanced. 

I.e. compare TV with VCL. In the VCL you define an event property 
(i.e. key pressed) which gets magically called, and can modify the 
methods in the object.

A first difference is that the event doesn't magically arrive at a 
control, but is distributed by the event handler logic, which is 
through overides completely under control of the programmer.

But I'm most impressed what happens when the event arrives at the right 
view. In general, you don't start to modify fields directly, but a new 
event is generated: a command. In effect, unlike the VCL, the program 
logic is steered by commands, and not by direct events like mouse clicks.

Add to this the enable/disable system of commands. I.e. disable cmCut and all menu 
bars, status bars, buttons, context menu's and whatever thing 
that can generate a cmCut turns grey.

IMO it is still even today one of the best designed event systems and I 
have to see a system that does it better...


More information about the fpc-devel mailing list