mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-05-02 15:03:42 +03:00
Deprecation message correction
This commit is contained in:
parent
af72132349
commit
f1c245c9c5
|
@ -133,7 +133,7 @@ class FreeTypeFont:
|
||||||
def __init__(self, font=None, size=10, index=0, encoding="", file=None):
|
def __init__(self, font=None, size=10, index=0, encoding="", file=None):
|
||||||
# FIXME: use service provider instead
|
# FIXME: use service provider instead
|
||||||
if file:
|
if file:
|
||||||
warnings.warn('`file` parameter deprecated, please use `font` instead.', DeprecationWarning)
|
warnings.warn('file parameter deprecated, please use font parameter instead.', DeprecationWarning)
|
||||||
font = file
|
font = file
|
||||||
|
|
||||||
if isinstance(font, basestring):
|
if isinstance(font, basestring):
|
||||||
|
@ -225,7 +225,7 @@ def truetype(font=None, size=10, index=0, encoding="", filename=None):
|
||||||
"Load a truetype font file."
|
"Load a truetype font file."
|
||||||
|
|
||||||
if filename:
|
if filename:
|
||||||
warnings.warn('`file` parameter deprecated, please use `font` instead.', DeprecationWarning)
|
warnings.warn('filename parameter deprecated, please use font parameter instead.', DeprecationWarning)
|
||||||
font = filename
|
font = filename
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user