-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Closed
Labels
AnacondaIssues with Anaconda's PillowIssues with Anaconda's PillowBugAny unexpected behavior, until confirmed feature.Any unexpected behavior, until confirmed feature.FontsPlatformA catchall for platform-relatedA catchall for platform-related
Description
What did you do?
I ran the following code:
from PIL import Image, ImageDraw, ImageFont, features
print(features.check('raqm'))
print(Image.PILLOW_VERSION)
img = Image.new('RGB', (800, 300), color = (73, 109, 137))
d = ImageDraw.Draw(img)
fnt = ImageFont.truetype('NotoSansTibetan-Regular.ttf', 24, layout_engine=ImageFont.LAYOUT_BASIC)
d.text((10, 10), "༄༅། །སྒྲུབ།", font=fnt, fill=(255, 255, 0))
img.save('result.png')
fnt = ImageFont.truetype('NotoSansTibetan-Regular.ttf', 24, layout_engine=ImageFont.LAYOUT_RAQM)
print("things work until...")
res = fnt.getmask("༄༅། །སྒྲུབ།", features=['ccmp', 'abvs', 'blws', 'calt', 'liga', 'kern', 'abvm', 'blwm', 'mkmk'])What did you expect to happen?
No segfault
What actually happened?
Here's the console output:
True
5.0.0
things work until...
Traceback (most recent call last):
File "testmarche.py", line 13, in <module>
res = fnt.getmask("༄༅། །སྒྲུབ།", features=['ccmp', 'abvs', 'blws', 'calt', 'liga', 'kern', 'abvm', 'blwm', 'mkmk'])
File "/usr/local/lib/python3.5/dist-packages/PIL/ImageFont.py", line 163, in getmask
return self.getmask2(text, mode, direction=direction, features=features)[0]
File "/usr/local/lib/python3.5/dist-packages/PIL/ImageFont.py", line 166, in getmask2
size, offset = self.font.getsize(text, direction, features)
OSError: invalid face handle
Erreur de segmentation
What versions of Pillow and Python are you using?
- Pillow 5.0.0
- Python 3.5.3
- libraqm is manually installed, branch
master, commitcf6ec2c4a31785c1092e38569225d1d6a294111b
Metadata
Metadata
Assignees
Labels
AnacondaIssues with Anaconda's PillowIssues with Anaconda's PillowBugAny unexpected behavior, until confirmed feature.Any unexpected behavior, until confirmed feature.FontsPlatformA catchall for platform-relatedA catchall for platform-related