fix overlap of image past margin

# fixes #62