diff --git a/README.md b/README.md index 4adde82..c74b1bd 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ Features How to Install -------------- - * Install Python 2.6 or newer. (**Python 3 is not supported.**) + * Install Python 2.6 or newer. (**For Python 3 support have a look at [pdfminer.six](https://github.com/goulu/pdfminer)**). * Download the source code. * Unpack it. * Run `setup.py`: diff --git a/pdfminer/latin_enc.py b/pdfminer/latin_enc.py index 41d219c..52dadc1 100644 --- a/pdfminer/latin_enc.py +++ b/pdfminer/latin_enc.py @@ -162,6 +162,7 @@ ENCODING = [ ('mu', None, 181, 181, 181), ('multiply', None, None, 215, 215), ('n', 110, 110, 110, 110), + ('nbspace', None, 202, 160, None), ('nine', 57, 57, 57, 57), ('ntilde', None, 150, 241, 241), ('numbersign', 35, 35, 35, 35), diff --git a/pdfminer/utils.py b/pdfminer/utils.py index b53c1c1..307c5e7 100644 --- a/pdfminer/utils.py +++ b/pdfminer/utils.py @@ -11,7 +11,7 @@ from sys import maxint as INF def apply_png_predictor(pred, colors, columns, bitspercomponent, data): if bitspercomponent != 8: # unsupported - raise ValueError(bitspercomponent) + raise ValueError("Unsupported `bitspercomponent': %d"%bitspercomponent) nbytes = colors*columns*bitspercomponent//8 i = 0 buf = b'' @@ -43,7 +43,7 @@ def apply_png_predictor(pred, colors, columns, bitspercomponent, data): line2 += chr(c) else: # unsupported - raise ValueError(ft) + raise ValueError("Unsupported predictor value: %d"%ft) buf += line2 line0 = line2 return buf diff --git a/setup.py b/setup.py index c9962fe..51779e7 100644 --- a/setup.py +++ b/setup.py @@ -18,6 +18,9 @@ PDF parser that can be used for other purposes instead of text analysis.''', author='Yusuke Shinyama', author_email='yusuke at cs dot nyu dot edu', url='http://euske.github.io/pdfminer/index.html', + install_requires=[ + 'pycrypto', + ], packages=[ 'pdfminer', ],