> Another issue that we must also clean up in tandem is our *Unix* font > code with the UnixFontManager class sitting between gdkFonts and > psFonts.
Pango has extremely powerful abstract way of handling fonts, so that the UnixFontManager would not be needed at all. Instead we would have a single XP font manager that would provide a convenient interface to Pango. It would hold the list of fonts/faces available through Pango and some basic functions to request a font from Pango, etc., but in essence it would be just a wrapper around various Pango calls. The whole bunch of PS classes would be moved into XP code, and reworked. We would have to create a function that would convert a PangoGlyphString into PS output; this might not be trivial, but the data stored in the PangoGlysphString does, I think, contain everything we need for that. Also, as Leonard mentioned, there are some OS projectes that generate PS using FreeType, so there is a good chance we might be able to borrow at least some code. The ttftool program we use on Unix would need to be reworked and moved into XP land, and also into AW itself (into some PS class), so that we could generated type 42 fonts from ttf on request when printing. This would make the use of ttf fonts on Unix entirly trasparent to the user; I have also been told that it is possible to generate type 42 fonts from ttf using only a limited set of glyphs from the original font, which would allow us to substantially reduce the size of our PS output. > Can we jump straight to using pangofonts everywhere? Is there someone > willing to work on this code? The only thing I am not sure about is the GUI, which will need font represantation native to the sytem, but that genrally concerns a single font. But otherwise if we use Pango, we will have to use the PangoFont objects, and I am going to work on that. > Havoc's posts on fontconfig are very convincing. I think we should > definately leverage this work so installing new fonts for abiword is > as easy as windows. I think, ultimately we do not want to be installing fonts for AbiWord at all, we just want to use fonts on the system. Pango will make that possible for us, because (1) it will filter out unsuitable fonts, (2) it will always find us some substitution for a non-existent font, say if Times New Roman is not found. What I like about the current font mechanims used the Pango FreeType back end, is that we could use it on all our platforms, for each platform would just need a different XftConfig file. Tomas
