Fixes image layout when app metadata is really long

Previously images would get written off the bottom of the page. This change makes sure that new pages are inserted if needed.
removed debugging line
Merge pull request #17 from panicinc/master

fixes image layout with long metatdata