Allows full tesseract configuration options
Allows full tesseract configuration options

The config argument don't currently work properly. It gives tesseract a single string, which tesseract can't recognize, and so the config options aren't implemented. A simple shlex.split() fixes that by splitting the config argument into individual strings and putting them to a list. I.e., run_tesseract(foo.png, bar, config="-psm 8 nobatch letters") will pass ["-psm", "8", "nobatch", "letters"] to tesseract, instead of ["-psm 8 nobatch letters"].

Please consider a commit, or another solution to this problem.
madmaze/pytesseract