[squeak-dev] Re: How to compile FreeType Plugin (FT2Plugin)?

Andreas Raab andreas.raab at gmx.de
Thu Mar 20 16:13:40 UTC 2008

José Luis Redrejo wrote:
> I've just tried it and the results are really wonderful. Bert said, OLPC 
> does not have sub-pixels, but I've tried it also on an OLPC and it looks 
> much better than the original image. Anyway, I have a some doubts:
> - I don't have a CRT monitor, do they look fine at it?
> - Any trick to generate new size/bold/italic fonts? automatically 
> generated bold fonts look really ugly...
> - If there is no hidden problem behind this approach, why hasn't it 
> already been implemented in the official images?

It's not scalable. Each font needs to be backed by a bitmap and if you 
need, say, five fonts at five size (which is less than a regular Squeak 
image ships with) you'll end up this:

totalForms := 5 "fonts" * 5 "faces" * 32 "derivedFonts".
totalMemory := 600 "width" * 300 "height" * 4 "depth" * totalForms.

The assumptions of memory consumption are based on the image that Juan 
has on his website (approx. 600x300x32bpp). Larger font sizes will have 
significantly larger memory requirement (due to geometric growth of the 
area) so this is a conservative estimate.

By this estimate, supporting 5 fonts in 5 sizes and all combinations of 
emphasis requires approx. 500MB of storage. Oops.

The approach will work well for a very small number of fonts but is not 
a scalable solution in general. As a side note StrikeFonts get away with 
a similar approach only by virtue of a) having originally 1/32 of the 
memory requirements (by using 1-bit forms instead of 32-bit forms) and 
b) being able to compute the derivative fonts on demand (so they don't 
need to be cached).

   - Andreas

More information about the Squeak-dev mailing list