I am using a simple script runs as toggle.sh process1 which toggles visibility of  process1 if it exists and if it doesn't exist then it launches process1. It is really simple but useful. I use it for several applications such as terminal, kate, nautilus and lyx. (each works like a drop down terminal with an assigned shortcut in gnome)  However I need a more sophisticated way to achieve this with a specific Chrome window. This is because the restriction of this script is there must be one-to-one correspondence between process-name and window-id. Any ideas how I can achieve this ? EDIT :To be more clear I want to toggle visibility of a window of chrome (for search purposes) and if it doesn't exists then create that window. One of the below might solve it but I couldn't find a way to do it : - Run an instance of chrome with a different process name and single-process option. (creating a symbolic link to chrome and naming it as dropdown-chrome-4-search wont work) For creation: create a chrome new-window change its title to say chrome-4-dropdown. For toggling: in the script get the ID of the window with title chrome-4-dropdown-purposes to toggle. (Don't know how to do the first creation step in the script)
Creating a specific chrome window and use it as drop-down search window
linux;x11;gnome;wmctrl