Robert "roc" O'Callahan has posted an update on the work to move Mozilla's graphics infrastructure to Cairo. Formerly known as Xr or Xr/Xc, Cairo is a cross-platform open-source vector graphics library. According to roc, migrating to Cairo will "give us modern 2D graphics capabilities (such as filling, stroking and clipping to paths, general affine transforms, and ubiquitious support for alpha transparency)." Cairo can send its output to a number of different backends, making it suitable for producing graphics for both screen and print. By utilising the Glitz library, Cairo can draw hardware-accelerated graphics with OpenGL, allowing Mozilla to take advantage of modern 3D display hardware.
In his weblog post, roc includes a screenshot of a Linux Mozilla Application Suite build using Cairo to render webpages and its XUL user interface. Performance needs work though: "Right now," roc says, "the speed is best described as somewhere between 'glacial' and 'proton decay'." Eventually, Cairo should make rendering webpages significantly faster for users with modern 3D hardware (the vast majority) and about the same as it is today for everybody else.
As it's cross-platform, Cairo will remove the need for lots of platform-specific graphics code and it will also provide a single "rendering pipeline" for all displayed content. Cairo has particular advantages for the recently checked-in canvas element and Mozilla's native Scalable Vector Graphics implementation. The multitude of Cairo backends should also make it simple to implement features like converting a webpage to a PDF file or saving a document as a PNG image.
The Mozilla2:GFXEvolution wiki page has more details about the plans for moving towards Cairo. The Cairo code will be wrapped in a set of thin C++ wrappers known as Thebes to make it easier to use. The Mozilla team will also be making significant contributions to the Cairo project itself. Last year, Cairo was relicensed under the Mozilla Public License (in addition to the LGPL), removing any license compatibility problems. Mozilla isn't the only backer of Cairo either: the GTK+ toolkit (used by GNOME) is moving towards Cairo as well.
Per chi segue la ML di AmigaOpenOffice avrà certamente letto che si sta pensando di portare su OS4 Cairo, se il buongiorno si vede dal mattino ...
