Public bug reported:

Binary package hint: python-imaging

#!/usr/bin/env python
"""Demonstrate a bug in Python Imaging Library.

Summary: PIL font renderer cuts off descender of some TrueType fonts

The FreeType font loader in the _imagingft component of
python-imaging does not always render the entire glyph.

Steps to reproduce:
1. Download FinkHeavy.ttf from
   http://www.angelfire.com/stars5/tkcpics2/wildworld/#downloads
2. Copy it to the .fonts folder in your home folder.
3. Run this Python program.

Expected result:
The bottom of the 'g' is round, as it appears in other programs.

Actual result:
The bottom of the 'g' is flat; the bottom has been cut off.

Unlike python-imaging, SDL_ttf does not have this problem.

"""
from PIL import Image, ImageDraw, ImageFont
import os

fontname = os.path.expanduser('~/.fonts/FinkHeavy.ttf')
im = Image.new('L', (256, 256))
dc = ImageDraw.Draw(im)
fh = ImageFont.truetype(fontname, 64)
dc.text((62, 64), "Hg", 254, fh)
im.show()

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: python-imaging 1.1.7-2
ProcVersionSignature: Ubuntu 2.6.35-22.35-generic 2.6.35.4
Uname: Linux 2.6.35-22-generic i686
NonfreeKernelModules: wl
Architecture: i386
Date: Thu Nov 18 16:41:17 2010
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
ProcEnviron:
 LANG=en_US.utf8
 SHELL=/bin/bash
SourcePackage: python-imaging

** Affects: python-imaging (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: apport-bug i386 maverick

-- 
PIL font renderer cuts off descender of some TrueType fonts
https://bugs.launchpad.net/bugs/677208
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to