[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]

Re: [XaraXtreme-dev] Rescanning available fonts



In message <0485dc284e.martin@xxxxxxxxxxxxxxxxxxx>
          Martin Wuerthner <lists@xxxxxxxxxxxxxxx> wrote:

> I am about to change the font system to no longer report "FreeType"
> fonts but rather report TrueType and Type1 fonts instead. This allows
> the font dropdown list to show the user which kind of font it is and,
> more importantly, allows the document save routines to save font
> information compatible with the Windows version. It has the added
> benefit that non-scalable fonts and virtual fonts introduced by
> fontconfig, e.g., "Monospaced", can be eliminated from the font list.

I have implemented the above and it fixes bugs 1066 and 1076 and also 
file saving. It does take a long time to enumerate fonts though 
because opening each font using Pango/FreeType is rather expensive. On 
my system (3.2GHz Pentium 4) with about 300 fonts installed, it takes 
6 seconds.

So, as I gathered, it is not practicable without a cache - the text 
tool calls the font enumerator each time it is selected and we cannot 
have such a long delay in that situation.

Martin