Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to snap the currently open tab(s) on Firefox (or any other browser) on Linux?

I have full user access to that machine...

share|improve this question

migrated from stackoverflow.com Apr 29 '11 at 11:02

This question came from our site for professional and enthusiast programmers.

What do you mean by "snap"? – Pekka 웃 Apr 28 '11 at 17:38

If by "snapping" you mean transferring one tab from one process on machine A, to another process on machine B, then no, you can't do that.

share|improve this answer

Here's a strategy:

  1. Get the X window id of the browser window containing the current tab that you want to snap. You can use wmctrl or xdotool for this.

  2. Use ImageMagick's import command to "snap" the currently open tab:

    $ import -windowid $window_id tabNNN.png

  3. Use some scripting to ask the browser to go to the next/previous tab in the list of open tabs. You can use xdotool to simulate the key presses or do a remote connection to the browser (chrome allows you to do this).

  4. Repeat from step 2.

Here's a one liner that captures all open windows in X:

$ for i in `xdotool search .`;do import -windowid $i $i.png;done

Good luck!

share|improve this answer
Sounds like a too time consuming procedure for now. Thanks for the effort... – Yotam Jun 29 '11 at 13:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.