Fix tiled TIFF saving when partial tiles will be used

If the image width and/or height are not multiples of the tile
dimensions, then the last tile in each row or column will be smaller
than the others.  This commit prevents an exception when that is the
case.
Restrict direct tile copying to single-tile images
Merge pull request #871 from melissalinkert/tile-export

Fix tiled TIFF reading and writing