[Openmcl-devel] Lisp User Interface LUI
ralex at cs.colorado.edu
Wed Jan 7 20:38:35 EST 2009
On Jan 4, 2009, at 3:49 PM, Terje Norderhaug wrote:
> On Jan 2, 2009, at 11:30 AM, Alexander Repenning wrote:
>> This may be a good moment to discuss some of the ideas regarding
>> the creation of LUI, the "Lisp User Interface as a cross platform,
>> but Mac first" open source GUI tool.
> Yes! Thank you for being a force in moving this forward. Count me in.
Excellent: Perhaps as next step I could just share some of our proof
of concept code. It would allow you to run examples but also to see
how hard or simple it would be to add more GUI controls.
>> Some fundamental ideas of LUI are:
>> - separation of platform specific and independent code: write
>> platform independent code or create specific Cocoa based extensions
>> - separation of procedural (Lisp) and declarative (XML syntax but
>> it is really Lisp: X-expressions http://www.cs.colorado.edu/~ralex/papers/PDF/X-expressions.pdf)
>> GUI information
>> - layout managers: interfaces that stretch and don't need, but do
>> allow, hardcoded coordinates/sizes.
> I favor an approach in which the user interface to a high degree
> automatically adapt to each platform. That is, the goal is NOT to
> create user interfaces that looks and works similar on the different
> platforms, but instead adheres to their different HUI conventions
> and usability practices. Case in point, I once hoped CLIM would be a
> good fit for adaptive user interfaces, but got disappointed.
I do like the adapt idea. I have seen some TCL interfaces that are
just a pain for most Mac users. Bottom line is that Mac interfaces
should not use Lisp as rationale to make bad interfaces. To a large
degree Apple seems to be getting away with non windows looking
interfaces on windows (iTunes, Safari). If Apple gives us these tools
I think we should use them. I would not want to replicate the CLIM
idea. Perhaps a better way that is not quite as adaptive would be to
deal with a 2 level approach. The first level would be low level
control wrappers such:
Currently we have this turn into a Cocoa control in CCL Mac and a
Window slider widget on Allegro. Modulo some size issue which can be
compensated for with automatic layout this can produce native looking
controls. Still, the guidelines on Mac and PC do differ. A simple
example would be the arrangement of OK, Cancel buttons. One could have
a higher level representation, also in XML, to capture this via high
level design pattern that may be rendered into the concrete stuff.
Initially, I think I would be OK with just the low level. We found
that in most cases one can come up with a design that looks good on
Macs and at least OK in Windows.
> Alexander is right in proposing external, XML based user interface
> declarations that are platform and programming language independent.
> It facilitates that non-LISP'ers design or modify the user interface
> without requiring involvement by the LISP programmer. Way to go!
> These files could even be available for optional customization by
> the end user, for example, by placing them in the application bundle
> and loading them at runtime.
That is right. With AgentCubes, which is the app that we are working
on, everything on the screen is a CLOS object that via XMlisp gets
automagically turned into XML and back. This XML captures not only GUI
specs but, for end users, more important files such as their documents
describing games (e.g., 3D content such as shapes, cameras,
scenes, ...) which in some cases they need to edit at the XML level.
The good news is they can.
> Some other XML-based user interface description formats:
> * XUL - https://developer.mozilla.org/en/The_Joy_of_XUL
> * XAML - http://en.wikipedia.org/wiki/Extensible_Application_Markup_Language
> * UIML - http://www.uiml.org/
> * UIDL - http://www.usixml.org/
> * XFORMS - http://www.w3.org/TR/xforms11/
Our XML is inspired by some of these formats, e.g., XUL. Many of these
formats are assuming that they are rendering content into a browser
window with little or no control for VERTICAL layout machinery because
web pages only change rendering when resizing width not height. This
may seem a detail but most "traditional" non browser windows must be
able to also layout vertically. At any rate, the idea is to use as
much as possible from existing specs but adding what is missing. Also
important is the fluent integration of Lisp and XML. We can just mix
At any rate, it may be best to give you something to play with to get
a better sense of the concrete way of making guis with XMLisp.
Prof. Alexander Repenning
University of Colorado
Computer Science Department
Boulder, CO 80309-430
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Openmcl-devel