Add support for max height and width parameters
Compatibility fixes for Python 3

Also includes more consistent ordering of query parameters
Merge pull request #15 from matt-thomson/issue4

Add maxheight and maxwidth parameters

Closes #4