Saturday, October 28, 2006

delving into McCLIM

I've taken the plunge and started working on a new backend for McCLIM using Graphic-Forms as the substrate. Thus, the result will be a native Win32 backend. Realistically, some time will have to pass before I've got enough functionality working that at least the standard demos can run. It's OK to make quick-and-dirty hacks just to see something pop up on the screen, but if I'm going to propose adding this backend to McCLIM for real at some point, then it needs to play by the rules.

There are plenty of good reasons to take this project on, but for me the most compelling argument is that CLIM represents a much higher-level way of thinking about GUI building. Since I think of myself as somewhat of a specialist in GUI development, this is very important. After I've climbed the somewhat steep learning curve, digesting new concepts along the way (like what the heck `flipping ink' is all about), I'll be that much stronger in my GUI-fu. I can take some of these concepts back to my design of Graphic-Forms -- not necessarily with the intention of directly incorporating CLIM concepts like presentation types, but as a way to take a fresh look at the services that GF provides. After all, GF is itself an abstraction layer over the Win32 User/GDI APIs and does some translation of raw Win32 concepts to Lisp-y abstractions.

A secondary benefit of this will be more code that uses Graphic-Forms, and maybe more users (albeit indirectly).

By the way -- hooray for open-source and Lisp and learning new things and having the ability to spend as much time as I want on this stuff!

Sunday, October 22, 2006

Graphic-Forms version 0.6.0

Release 0.6.0 of Graphic-Forms, a Common Lisp library for Windows GUI programming, is now available. This is an alpha release, meaning that the feature set and API have not yet stabilized.

Here is what's new in this release:

. CFFI snapshot 060925 or later is now required if you are running CLISP 2.40 or later (due to a change in the argument list of CLISP's FFI:FOREIGN-LIBRARY-FUNCTION).

. Completely revamped the Programming Reference. DocBook/XSL is now used for help authoring, and the manual is delivered in HTML Help format.

. Implemented scrolling protocol and related helper objects and functions to facilitate scrolling functionality in applications:

* window styles :horizontal-scrollbar and :vertical-scrollbar

* functions to retrieve window scrollbars

* GFW:EVENT-SCROLL function for handling low-level scrolling events

* GFW:SCROLLING-HELPER for automatic management of a scrollable child panel and window scrollbars (works in combination with GFW:HEAP-LAYOUT)

* integral scrolling and resizing for step sizes greater than 1

. Initial list box control functionality implemented:

* three selection modes (none / multiple / extend)

* list item data comprised by arbitrary application-defined data

* application defined sorting predicates

* querying and programmatic control of item selection states

* customizability of vertical scrollbar mode and keyboard input

Additional list box features are planned for a future release.

. Implemented stand-alone scrollbar and slider control types.

. Renamed functions that query the standard color, file, and font dialogs to make their naming scheme more consistent.

. Implemented GFW:EVENT-PRE-RESIZE function so that applications can customize the behavior of a window's size drag rectangle.

. Implemented GFW:EVENT-PRE-MOVE function so that applications can customize the behavior of a window's move drag rectangle.

. Improved GFW:HEAP-LAYOUT such that it obeys the top child's minimum and maximum sizes, if any such sizes are set.

. Added GFG:FONT method for querying the current font selected for a window.

. Did some housecleaning of the item-manager protocol and heavily refactored the implementation of item-manager base functionality.

. Implemented GFW:ENABLE-REDRAW to enable applications to temporarily disable (and later re-enable) drawing of widget content.

. Fixed a bug in GFW:CHECKED-P (and GFW:SELECTED-P) for checkbox and radio button -style buttons.

. Fixed a bug in the initialization of the paint rectangle in the WM_PAINT message handling method; the correct rectangle is now passed to
GFW:EVENT-PAINT

. Fixed a bug in the SETF functions for GFW:MAXIMUM-SIZE and GFW:MINIMUM-SIZE for windows whereby the size value was not being set in the appropriate slot if there were no layout set for the window.

The README.txt file in the release zip file also has additional important information about this release.

Download the release zip file here:
http://prdownloads.sourceforge.net/graphic-forms/graphic-forms-0.6.0.zip?download

The project website is:
http://common-lisp.net/project/graphic-forms/

Jack Unrue
jdunrue (at) gmail (dot) com
22 October 2006

Sunday, October 1, 2006

new FAQ page

I posted a new FAQ page for Graphic-Forms here. As much as this is intended to advocate my project, hopefully it also helps advocate in favor of GUI programming in Common Lisp on Windows. Comments and suggestions are welcome.