ref: 6c5c62c349b2ce6c362a9c7107a82e8bf73c89fd
parent: 7500dff58934b46b8233f36a25be722de87135e8
author: Mike Swanson <[email protected]>
date: Thu May 12 04:48:16 EDT 2016
textscreen/fonts: Support Pillow in addition to PIL
--- a/textscreen/fonts/convert-font
+++ b/textscreen/fonts/convert-font
@@ -26,9 +26,13 @@
try:
import Image
except ImportError:
- print("WARNING: Could not update %s."
- "Please install the Python Imaging library." % sys.argv[2])
- sys.exit(0)
+ try:
+ from PIL import Image
+ except ImportError:
+ print("WARNING: Could not update %s. "
+ "Please install the Python Imaging library or Pillow."
+ % sys.argv[3])
+ sys.exit(0)
def generate_font_data(filename):