* Drawing
Mono provides two mechanism to draw. The first exposes the
Microsoft System.Drawing API and the second exposes the Cairo API.
* System.Drawing
The System.Drawing implementation in Mono is designed to be
compatible with the Microsoft API. The imaging model is very
similar to the PDF 1.4 composition-based imaging model.
Our implementation is a C# wrapper around the GDI+ C API (also
called the "GDI+
Flat API").
In Windows Mono uses the GDI+ library that is included
with the operating system, while in Unix we provide an
implementation of this API which uses Cairo to do the heavy
lifting.
The implementation of GDI+ lives in mcs/class/System.Drawing
in the gdiplus directory and requires Cairo to be installed
to get the package built.
The C# code that implement System.Drawing is the same for
Windows and Unix builds.
Since this is an implementation of an existing Microsoft API
no architectural changes go here.
* Mono.Cairo
The Mono.Cairo.dll assembly exposes the Cairo API to managed
applications. The mapping is a pretty straightforward one,
and the programming model is very close to the C API.
This API is still unstable due to the nature of the underlying
API being used and will be revisited as Cairo evolves.