Fog Creek Software
Discussion Board




Designing Windows GUI Plumbing

In the discussion of state machines, it was mentioned that they (state machines) are a poor design choice when modeling Windows GUI. If your app has many windows/dialogs/forms, what underlying model are you using to bring structure to your program?

Floridian
Monday, December 15, 2003

Event based maybe...


Monday, December 15, 2003

I didn't see any comments about state machines being poor models for GUI systems in the state machine discussion.  Can you point out what you're referring to?  I think certain kinds of state machines would be excellent models for most GUI systems, so the comment would seem to be contrary to my understanding. 

hum
Monday, December 15, 2003

I have really only done server side work, so I would be greatly interested in other's opinions on this topic as well.

At the moment, I am getting involved with .NET, which has been great so far, and I really like the UI components they have provided.  Also, the way form inheritance has been implemented has been very useful.  Despite this, I have started to roll a UI framework by hand.  Its going pretty well, but any further insights would be great.

Also, I have decided to go with an inductive user interface, so this has added some complexity to the problem.  I know that this has been discussed on the board previously, but there are really very few articles detailing the implementation side of things.  Any suggestions on this top would be greatly appreciated as well.

Canuck
Monday, December 15, 2003

Hum,

the comment was posted in a previous discussion, the link to which was provided by Bored Bystander.

Floridian
Monday, December 15, 2003

Here it is:

http://discuss.fogcreek.com/joelonsoftware/default.asp?cmd=show&ixPost=30520&ixReplies=18

Look at the last message.

Floridian
Monday, December 15, 2003

Thanks for the pointer.  Looks like it's a reference to the last posting in the topic.  It's true that a state machine can turn into a real mess and be very difficult to understand.  This is especially the case if your only accessible level of abstraction on the machine is at the level of code.  I can see why it would be discouraging.

At the same time, though, a well designed (hierarchical) state machine, properly managed and documented, is one of the best ways I know of to handle reactive systems like GUIs and to make the behavior of the system clear to consumers of the system (both end users and other developers).

hum
Monday, December 15, 2003

My advice:

Use a good RAD tool, use whatever model the RAD tool offers for the GUI, and use the model of your choice for the application.

Even if there is an impedance mismatch between the model your RAD tool is using and the model your app's guts are using, you will still develop faster, because RAD is, well, Rapid.

X
Tuesday, December 16, 2003

*  Recent Topics

*  Fog Creek Home