Pharo Application Framework aka Morphic View Framework

January 31, 2012

Sharing this little framework that should go a long way to ease creating large applications ( currently morphic oriented).

AbstractMorphicView subclass: #MyNewView …



‘panel1’ -> #SomeOtherView.
‘label1’ -> #LabelMorph.
‘text1’ -> #PluggableTextMorph.
‘button1’ -> #PluggableButtonMorph.


‘widgetNameInMorphsDictionary’ -> {
#fractions -> (0 @ 0 corner: 1 @ 0.5). ” fractional value 0 to 1 range ”
#offsets -> (10 @ 10 corner: 0 @ 0). ” offsets relative to the fractional position ”

“… add other widgetspecs…”

Thats it.. you should have a prototype UI neatly laid out.. and then specify: #morphsPrimaryPropertiesSpecs and #morphsSecondaryPropertiesSpecs for full functionality that composes views inside views and scales well.

AbstractSimpleMorphicView can make it simpler for TableLayout stuff without requiring #layoutSpecsArray.

Look through the Tests: TestNewProportionalMorphicFromSpecsView , TestNewSimpleMorphicView and its pairs.. should give a good startup to the system..

Will share a better guide / pdf if anyone sees more value to this framework.. I am currently able to work this out for fairly usable apps and will address creating a UI Builder to spit out specs, a Projects browser and a Single Tabbed Class view browser that displays all the methods in one window and eases switching between methods/ classes as we currently see. Somewhat of a normal IDE people see in the outside world.


Intent is to have a quick and easier handle over building UI’s in Pharo that is flexible, scalable and integrates as much of the basic patterns of enterprise architecture incrementally.

PharoMorphicView is an attempt to streamline the morphic composition capability with:

* Spec based and optionally direct composition

* Layout specs/ defaults are clear and easy

* Integrate the basics of constants dictionary , locale translation, logging …

* Bring in the optimization capability of NamedPrototype or qualified combination of singleton, prototype, factory instantiations

* Integrate Configuration based development with a simple ini reader

** Some more extras are also available.. notably the XML-RPC-Jdbc that will require the counterpart server code in groovy that I have.. to couple up effectively

* Eventually extend this and integrate it into a Pharo Tablet / Desktop Runtime IDE that allows a marketplace like system to simply pull in applications in Pharo and work with akin to the iStore … that of course is a longer term goal..

***** Read the class side comment methods of ApplicationFrameworkDocumentation in the Core package to get a description of the intent, vision, roadmap and where this is now..

Load the following to get started and play with and then choose what to keep and work with..

Examples and Tests should be self explanatory for most..

All of it is shared in : Do check and load the latest version of the package(s) next week onwards.. as it maybe updated..




Support packages:


As also if interested in the XMLRPC stuff.. that will incrementally become central to the distributed computing pic…

These will be from their proper locations..  in squeaksource..