[Haskell] ANNOUNCE: Phooey -- a Functional UI library for Haskell

Conal Elliott conal at conal.net
Tue Dec 12 02:17:46 EST 2006

Announcing Phooey <http://conal.net/phooey>, a functional UI library for

GUIs are usually programmed in an "unnatural" style, in that implementation
dependencies are inverted, relative to logical dependencies. This reversal
results directly from the imperative orientation of most GUI libraries.
While outputs depend on inputs from a user and semantic point of view, the
imperative approach imposes an implementation dependence of inputs on

Phooey ("*Ph*unctional *oo*s*e*r *y*nterfaces") retains the functional
style, in which outputs are expressed in terms of inputs. In addition,
Phooey supports dynamic input bounds, flexible layout, and
mutually-referential widgets.

As an example of Phooey's style, below is a simple shopping list GUI. The *
total* displayed at the bottom of the window always shows the sum of the
values of the *apples* and *bananas* input sliders. When a user changes the
inputs, the output updates accordingly.

Phooey is structured as an arrow, and this example uses arrow notation. The

    ui1 :: UI () ()
    ui1 = title "Shopping List" $
          proc () -> do
            a <- title "apples"  (islider 3) -< (0,10)
            b <- title "bananas" (islider 7) -< (0,10)
            title "total" showDisplay        -< a+b

I am working on a paper about Phooey. For now, please see the Haddock
documentation <http://darcs.haskell.org/packages/phooey/doc> (which includes
more examples), and try the code via

darcs get http://darcs.haskell.org/packages/phooey --partial

Directions for building are in the
Distribution tarballs are
here <http://darcs.haskell.org/packages/phooey/dist>.

Comments and collaboration are very welcome!


       - Conal

P.S. I'm very grateful for Don Stewart's recent pointers on how to create &
release Haskell projects.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell/attachments/20061211/3eb471f0/attachment.htm

More information about the Haskell mailing list