[Tux4kids-tuxtype-dev] SDL_Pango, SDL_ttf, and the default font

Matthew Trey tux4kids at treyhome.com
Thu Sep 10 14:43:14 UTC 2009


I spent all of yesterday trying to figure out why scripted lessons, more
specifically custom text within scripted lessons was displaying different
between windows and Linux.  The answer is a difference between how Pango and
TTF were drawing the text passed to them.  I am using SDL_Pango 0.1.2-8 and
SDL_ttf 2.0.9-4.  What is happening is that pango draws the text pretty
close to the upper left corner of the surface, yet ttf adds a significant
gap before the text, drawing it down and to the right, so no consistent
rendering exists.

 

I believe this is actually due to the font file AndikaDesRevG.ttf, I
burrowed ariel.ttf from windows and used it in place, and both pango and ttf
rendered the text exactly the same, which is what should happen, as
functions outside of SDL_extras should not care which method is used.  If
possible, could someone confirm that they are seeing the same thing on their
end, and if there is indeed an issue with the font, a substitute should be
considered.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/tux4kids-tuxtype-dev/attachments/20090910/2aa12039/attachment.htm>


More information about the Tux4kids-tuxtype-dev mailing list