[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[BUG] Re: [pygame] Windows, Pygame and FreeSans?
- To: pygame-users@xxxxxxxx
- Subject: [BUG] Re: [pygame] Windows, Pygame and FreeSans?
- From: "René Dudfield" <renesd@xxxxxxxxx>
- Date: Fri, 17 Aug 2007 08:12:58 +1000
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: pygame-users-outgoing@xxxxxxxx
- Delivered-to: pygame-users@xxxxxxxx
- Delivery-date: Thu, 16 Aug 2007 18:13:06 -0400
- Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=SmgDevZRJ6htSYuEdk6RRj3jI7HO0NK7lf97r2weBpjvofsWwIDk8SudlP+nNvPCrcnWrmijitGq2SyHyVNmplGkbKZM3kxd+/01jIYnYd8OB54056sA8GUzZDeFjA4el6LeywegDUn6uQlHJaA48bMHmzmeWGMvo/kmbacCCAg=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=LDo4ww0z03uw+Rh3r9b8nTUVEJ6QHEvPVqNxH6HKHZy2BJKrjZ24AQC3BF0gixrXbQxi5Nx2VSQIoF/OMKEMUJt/ykUjorVmmlecTXNjP5pJgnMUIpGi5fE9VnacdSLNLej6dzzMSzr0+1AzEPhsbkoOrD89/sNU62bLJ/r1Mss=
- In-reply-to: <46C4B9D8.6090903@xxxxxxxxxx>
- References: <46C4B9D8.6090903@xxxxxxxxxx>
- Reply-to: pygame-users@xxxxxxxx
- Sender: owner-pygame-users@xxxxxxxx
hi,
they should be rendering exactly the same, as they don't use the OS
facilities for font rendering.
It's likely you have different freetype/SDL_ttf libraries on windows and linux?
Which version do you have of pygame on windows?
Cheers,
On 8/17/07, Ethan Glasser-Camp <glasse@xxxxxxxxxx> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi,
>
> In tinkering, I switched my game to use FreeSans (from the
> ttf-freefont package) rather than FreeSansBold, only to discover that
> this gives rendered text a weird "double-spaced" look on Windows.
> Probing deeper, I discovered that on my Linux machine, I get these
> results:
>
> >>> f = pygame.font.Font('freesans.ttf', 17)
> >>> f.get_ascent()
> 14
> >>> f.get_descent()
> - -3
>
> Whereas on Windows, the same font has an ascent of 21 and a descent of
> - -7! I can get the text to render "correctly" by ignoring the ascent
> and descent and just using the figures I got on my Linux machine, but
> I'd really like to know why the different figures. (I copied the .ttf
> file over to the Windows machine, so it's the same file.) How can I
> debug this? Open the font up in FontForge or something?
>
> Ethan
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFGxLnQhRlgoLPrRPwRAsZ+AJ9xu5igMQa108W78sEgkonsu/dblQCgjWVY
> X3UfMbON9KpN7gJ9p2vwWKI=
> =EPpD
> -----END PGP SIGNATURE-----
>