in reply to Website screenshot

You can use Mozilla::Mechanize to drive Mozilla/Firefox to the target site.

Mozilla::Mechanize seems to be based on Gtk::MozEmbed, which just seems to implement a GTK+ widget using the mozilla embedding API to render the content.

You should be able to get an X11 window handle for the widget and so then you should be able to use many different methods to obtain the contents of the window as an image.

It's not generally an easy thing to do.

On the other hand, there's a Firefox addon called "Screen Grab!" which captures a web page as image in the format of your choice. You might try to automate that in some way (eg, via Javascript and XPCOM APIs).

-David.