set an upper limit to number of lines of image refs closes #16