[racket] new GUI and drawing libraries in v5.0.99.1
While we're still getting the v5.0.2 release out the door, the
development repository has moved to v5.0.99.1 (leading up to a v5.1
release in early February).
The Racket GUI and drawing core is completely reimplemented in
v5.0.99.1. We've thrown out about 200,000 lines of C++ code that built
on Xt, Win32, and Carbon. We've replaced it with about 30,000 lines of
Racket code that builds on Gtk, Win32, Cocoa, Cairo, and Pango.
On the surface, Windows and Mac OS X users will see only small changes
due to the reimplementation. Unix/X users will see more dramatic
changes; building on Gtk means that DrRacket and other Racket GUI
programs take on your desktop theme for menus, buttons, and other GUI
widgets. Through Pango and Cairo, text handling is also better than
before on Unix/X, especially when printing.
Racket can build and install on Unix systems without Gtk libraries,
but you must install Gtk to run programs that use the Racket GUI
library; modern distributions of Unix variants include Gtk, so that's
unlikely to be a problem. When you build Racket from source on Windows
or Mac OS X, Pango and Cairo libraries are automatically downloaded
and installed along with the main Racket binaries (i.e., not
system-wide). Along similar lines, stand-alone GUI executables for
Unix/X platforms rely on a system installation of Gtk, while packaging
a stand-alone GUI application for Windows or Mac OS X includes the
necessary libraries in the package.
The new GUI and drawing library includes several API improvements and
a few incompatibilities:
* You can run GUI programs with just `racket', instead of having to
use `gracket'. Depending on how much your platform distinguishes
between GUI and console applications, though, there may still be an
advantage to using `gracket' (i.e., to tell the OS that you mean to
start a GUI application or that you want a single instance of the
application).
* Most of the drawing library has moved to `racket/draw', which you
can use without the rest of the GUI library --- and, in the case of
Unix platforms, without an X-server connection. (The documentation
does not yet reflect this split, but that will be fixed soon.)
* The drawing library includes some new capabilities, such as
rotation, affine transformations, and bitmaps with alpha channels.
Xor drawing is no longer supported.
See "Porting from v5.0.x to v5.1" in the "Release Notes" section of
the documentation for more information. Those notes are also
accessible as
http://git.racket-lang.org/plt/blob/HEAD:/doc/release-notes/racket/Draw_and_GUI_5_1.txt
Some of us have been using the new GUI and drawing implementation as
our main version of Racket for everyday work, but it is not yet up to
release quality. You will find bugs in v5.0.99.1; please report them,
and with your help, we'll get the new libraries in shape by January.