Is it possible to do this in linux?

New to Debian (Or Linux in general)? Ask your questions here!

Re: Is it possible to do this in linux?

Postby emil_21 » 2017-04-19 06:14

debiman wrote:very nice, but you still haven't told us what you want to achieve. but one step closer

anyhow, you've been given plenty of hints now, it's your turn now.

I need a script that can do this: when the mouse touch the bottom of the screen, and the firefox is the active window, the script to send ctrl+shift+e key press to the firefox window. This will open the tab groups panel in firefox. This way i can switch between tabs by clicking on the tab thumbnail in the tab group panel, since i like my tabbar to be hidden.
When the mouse touch the bottom of the screen and firefox is not the active window the script should not be activated.
Posts: 24
Joined: 2017-04-14 06:13

Re: Is it possible to do this in linux?

Postby debiman » 2017-04-19 15:28

yes this is scriptable with the above mentioned tools.
i'll just add wmctrl to the pool of available utilities.
you know, in linux there's almost always more than 1 way to skin a cat.

if you've never done anything like this on linux, there will be a learning curve, and i think it is clear that this is a highly personal setup so you'll have to make it yourself.

i suggest this workflow:
1) see if you can trigger a command on touching certain hot corners (screen edge). sometimes the window manager already has the ability, sometimes you can install a separate app for that, e.g. ... 3672.shtml or (but already packaged versions may exist in your repos, search "hot corner")

2) write a shell script (most probably bash) that checks if the right window is in focus, and if so, performs the necessary actions. i think xdotool can do most, if not all, of what you require. be prepared to use wmctrl also. maybe also xprop, xwininfo etc.
User avatar
Posts: 2405
Joined: 2013-03-12 07:18


Return to Beginners Questions

Who is online

Users browsing this forum: No registered users and 2 guests