mozshot icon indicating copy to clipboard operation
mozshot copied to clipboard

screenshot service with mozilla

===================================================

Mozshot was obsolete, taken over by Blinky; https://github.com/sugi/blinky

===================================================


README

MozShot - Web site thumbnail service by gtkmozembed.

Copyright (C) 2005 Tatsuki Sugiura [email protected] Released unlder the License same as Ruby.

This was based on MozSnapshooter written by Mirko Maischberger. http://mirko.lilik.it/Ruby-GNOME2/moz-snapshooter.rb

Origianl idea by Andrew McCall - http://www.hackdiary.com/archives/000055.html

And I refered many similar implementation. Thanks for all!

Requirement

  • mozshot.rb (simple)
    • X server
    • ruby 1.8 above
    • ruby gnome2
    • ruby gtkmozembed binding (included in ruby gnome2)
  • mozshot.rb (daemon mode)
    • drb + rinda
  • Sample CGI interface
    • apache + mod_ssi
    • Rmagick (Ruby ImageMagick Interface)

How to use

Simple way:

Type below in your XTerminal.

mozshot http://www.google.com/ shot.png

Daemon mode:

run TupleSpace daemon

./ts.rb &

run snapshot daemon

./mozshot -d &

run client

./client.rb http://foo.bar

Tips

  • To supress scrollbar

    Add "body { overflow: hidden !important }" to ~/.mozilla/mozshot/default/chrome/userContent.css.

  • To change default language

    Add setting to ~/.mozilla/mozshot/default/user.js. Japanese example followed;

    user_pref("intl.accept_languages", "ja, en-us, en"); user_pref("intl.charset.default", "Shift_JIS"); user_pref("intl.charset.detector", "ja_parallel_state_machine");

  • To get screenshot of https://... URI with XULRunner, you need to make disable modal dialog.

    user_pref("security.warn_entering_secure", false); user_pref("security.warn_entering_weak", false); user_pref("security.warn_leaving_secure", false); user_pref("security.warn_viewing_mixed", false);