19

I've been looking for this for a while, and I can't find it anywhere.

I need to be able to zoom (equivalent of ctrl + shift + '+') via the terminal. I've tried xdotool, but do not know how to get it to register '+' (or the = key).

This is very important and has been a life dream of mine. Now that I'm somewhat capable with Ubuntu, I feel that I can finally achieve this goal: I need to make an alias such that when I type in "enhance", everything zooms.

6
  • Have you tried using the magnifier?
    – muru
    Oct 13, 2014 at 17:25
  • With Kubuntu and Konsole: Ctrl++ and Ctrl+-.
    – Cyrus
    Oct 13, 2014 at 17:48
  • 1
    What terminal are you using? What do you mean "zoom"? Increasing the text size or actually zooming?
    – terdon
    Oct 13, 2014 at 18:19
  • I haven't tried using the magnifier, but I want to be able to type a command into the terminal and have it zoom (actual zooming). I'm using whatever terminal comes with Ubuntu 14.04. I'm not looking for a keyboard shortcut—I want to be able to type something into the terminal Oct 13, 2014 at 18:26
  • @AmagicalFishy the magnifier can be launched using a shortcut, so you can write an xdotool command similar to these to launch it.
    – muru
    Oct 13, 2014 at 18:49

1 Answer 1

31

The xdotool (command-line X11 automation tool) commands to use are:

  • Zoom in (AKA Ctrl++)

     xdotool key Ctrl+plus
    
  • Zoom out (AKA Ctrl+-)

     xdotool key Ctrl+minus
    
  • Normal size (AKA Ctrl+0)

     xdotool key Ctrl+0
    

This won't work on Wayland (echo $XDG_SESSION_TYPE).

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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