add support for GraphicsMagick

cleanup logic and support ImageMagick - GraphicsMagick.
fyi: GraphicsMagick seems to be doing a better job creating screenshots for PDF