How Do You Do Business Apps?

Stefan Matthias Aust sma at 3plus4.de
Wed Feb 23 21:47:01 UTC 2000


>	I've been working with Dolphin ST for a little while now (and a bit of
>VW before), but I'm having trouble discovering how to do non-graphics
>related "business" apps in Squeak. I've been though the tutorial on Morphic
>that shows you how to create a bouncing rainbow colored ball, but how do
>you go about creating windows with text fields and buttons and whatnot?
>Dolphin has a tutorial that walks you though creating a bank account
>program with windows for viewing accounts, adding transactions, etc. Is
>there some Squeak doc that I've missed that shows this level of detail? Or
>anything else that would get me started with textfields, scrollbars,
>buttons, etc?

For business applications, I'd recommend to stay with Dolphin ST.  Its
application framework (called MVP - Model View Presenter) is IMHO one of
the best things invented for Smalltalk.  Squeak has nothing comparable (yet).

In Squeak you can choose to work with the old windowing toolkit (aka MVC)
and the newer system called Morphic.  Both feature only the most basic
widgets (like buttons, text fields, simple single selection lists and popup
menus).  Morphic has a few more widgets like a hierarchical list (aka tree
view) or a book morph (aka tabbed pane).  The look isn't very pleasant IMHO
but right now somebody is working on this.  The feel is - compared to
Windows - still quite different.  MVC is similar to MVP as you can (and
should) separate the model and its view.  There're however no adaptor
classes as in Dolphin (or VisualWorks - ValueModel hierarchy).  Squeak
achieves a similar result by offering pluggable widgets.  This means you
can specify a number of method selectors which are then used by the widget
to get or set the values.  I like Dolphin better here.  In Morphic there's
no real support for separating model and view.  You could do this but
normally morphs are both.  I'm not convinced that this is a good idea.  

A really nice feature is however that Morphic is its own UI builder.  You
can use drag and drop to compose a UI out of Morphs.  You may want to check
out the Alignment morph to layout morphs.  Java-style layout managers or at
least the flexibilty of Dolphin or VW would be nicer here.  Once you got
your UI, you can save it as into a .morph file.  That's again a nice thing.

To sum up, there's a lot of work to do to get a decent UI.


bye
--
Stefan Matthias Aust  //  Bevor wir fallen, fallen wir lieber auf.





More information about the Squeak-dev mailing list