Erlang for desktop applications?

Robert Raschke rrerlang@REDACTED
Tue Aug 15 14:05:57 CEST 2006


Mats wrote:
>    GUI programming is pretty complicated, because GUIs are complicated. 
> concurrency is not really the main problem (how often do you really want to 
> press two buttons at the same time?). 

I agree that writing a GUI is hard.  But, in my experience dealing
with the user input side of things is actually quite easy.  The hard
part (for me) comes when other events need to get reflected in the
GUI.  This is where you end up having real concurrency (or
alternatively you write a cheap GUI that has update buttons :-).  You
need to be able to sensibly reflect the users actions, while at the
same time show changes in any underlying models (a noddy example is a
filebrowser, it needs to show the current state of the folders, not
the one that was current when you first opened it).

Conceptually, MVC tries to address some of this.  And if you view the
MVC components as parallel entities, the model works quite neatly.

But if you are stuck in a sequential model (even one that can use
threads), then changes to your Model need to be explicitly serialised,
someone needs to make decisions on when to update the View, and so on.
I have so far not come across any nice support in any environment
(even Smalltalk) that would allow the writing of MVC components as
parallel, communicating entities.  My guess is that at some stage in
the design of all of these, someone decided to sacrifice elegance and
ease of use to the god of efficiency.  I'll stop ranting here.

Robby




More information about the erlang-questions mailing list