Xfce Forum

Sub domains
 

You are not logged in.

#1 2017-07-27 15:26:15

Uhu
Member
Registered: 2017-07-27
Posts: 4

xfwm : launcher with predefined zoom ?

Hello everyone :-) :-), i have a question about xfwm. I would like to create a launcher in the taskbar that would allow by clicking on it to achieve a predefined zoom level. In fact it often happens to me to be away from the screen and therefore the keyboard, so it is difficult for me to use the shortcut alt + mousewheel. It would also be necessary that I create another launcher that resets xfwm in normal mode after the zoom desktop.
I looked in the wiki but I found nothing as an indication. Thank you for your answers

Offline

#2 2017-07-27 19:37:00

sixsixfive
Member
From: behind you
Registered: 2012-04-08
Posts: 579
Website

Re: xfwm : launcher with predefined zoom ?

you could try http://magnifier.sourceforge.net/#introduction however i never tried that but compiz and kwin supports fullscreen zoom also have a look here its even with xfce:

https://www.youtube.com/watch?v=0ZBzM0e7KL8
https://www.youtube.com/watch?v=jY_FwQBII3M

Last edited by sixsixfive (2017-07-27 19:39:07)

Offline

#3 2017-07-27 19:53:29

Uhu
Member
Registered: 2017-07-27
Posts: 4

Re: xfwm : launcher with predefined zoom ?

Thanks for answering. Nevertheless I do not need a software magnifier (that I already have: xzoom, but that does not correspond to what I'm looking for), nor even a window manager like kwin because xfwm the window manager of xfce can already do a zoom desktop with alt + mousewheel shortcuts.
Just that one needs the keyboard to do it but I happen to be away from the keyboard.
So I'm looking for the command that made the command or shortcut alt + mousewheel x2 or x3, to put it in a launcher on the panel. Sorry if I express myself badly, I'm bad in english.

Offline

#4 2017-07-27 20:04:19

sixsixfive
Member
From: behind you
Registered: 2012-04-08
Posts: 579
Website

Offline

#5 2017-07-27 21:09:04

Uhu
Member
Registered: 2017-07-27
Posts: 4

Re: xfwm : launcher with predefined zoom ?

Thanks a lot !! :-) xdotool do the job.

Here is the command that I put in two .sh script with a launcher for each in the panel, there is surely way to improve it but in any case it works.

zoom in:

xdotool keydown Alt click 4 click 4 click 4 click 4 keyup Alt

zoom out:

xdotool keydown Alt click 5 click 5 click 5 click 5 keyup Alt

I wonder if there is no way to make so that there is only one launcher that made the command to zoom in by clicking once and then the command that zoom out by clicking a second Times on the same launcher...

Offline

#6 2017-07-27 21:20:11

MountainDewManiac
Member
From: Where Mr. Bankruptcy is Prez
Registered: 2013-03-24
Posts: 1,115

Re: xfwm : launcher with predefined zoom ?

Can you just get a five-button mouse and map one of the "extra" buttons as an Alt key, then use the already-present zoom? Or does it (mapping mouse buttons) not work like that?

Regards,
MDM


Mountain Dew Maniac

How to Ask for Help <=== Click on this link

Offline

#7 2017-07-28 17:29:18

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,493

Re: xfwm : launcher with predefined zoom ?

Uhu wrote:

I wonder if there is no way to make so that there is only one launcher that made the command to zoom in by clicking once and then the command that zoom out by clicking a second Times on the same launcher...

How about something like this:

#!/bin/bash

[ ! -e /tmp/.zoomer_state ] && touch /tmp/.zoomer_state

case $(cat /tmp/.zoomer_state) in
	0) #normal state so zoom
		xdotool keydown Alt click 4 click 4 click 4 click 4 keyup Alt
		echo 1 > /tmp/.zoomer_state
	;;
	1) #zoomed state so return to normal
		xdotool keydown Alt click 5 click 5 click 5 click 5 keyup Alt
		echo 0 > /tmp/.zoomer_state
	;;
	*) #unknown state so assume normal and zoom
		xdotool keydown Alt click 4 click 4 click 4 click 4 keyup Alt
		echo 1 > /tmp/.zoomer_state
	;;
esac

exit 0

Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#8 2017-07-28 18:51:10

Uhu
Member
Registered: 2017-07-27
Posts: 4

Re: xfwm : launcher with predefined zoom ?

Thank you very much ToZ for your script which is really handy. :-)

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.015 seconds, 7 queries executed - Memory usage: 546.79 KiB (Peak: 547.63 KiB) ]