Corrected error handling

This commit is contained in:
Andrew Murray 2019-06-23 13:31:07 +10:00 committed by Michal Čihař
parent 3f9af46f88
commit 0ad433c963

View File

@ -545,6 +545,8 @@ def truetype(font=None, size=10, index=0, encoding="", layout_engine=None):
try:
return freetype(font)
except IOError:
if not isPath(font):
raise
ttf_filename = os.path.basename(font)
dirs = []