Full screen window command from Linux terminal?

1

On Cinnamon, you can set a hotkey to force the active window into full screen mode; many programs have a full screen toggle built in. What I'm wondering is, what's the command that's being sent? How would you issue such a command in a terminal emulator to resize an application window so that it includes the space occupied by taskbars/panels?

Jon.D.

Posted 2017-11-05T20:21:05.953

Reputation: 113

3It's setting the _NET_WM_STATE_FULLSCREEN atom on the window. – Ignacio Vazquez-Abrams – 2017-11-05T20:22:51.943

2Have a look at wmctrl. – dirkt – 2017-11-06T08:19:34.453

Answers

1

Based on @dirkt's comment I went and had a look at wmctrl, which is a command line tool that let's you set these yourself. If you'd like to do things like toggle fullscreen for whatever programs you like from a shell script or any other custom place, this is ideal for that.

Here's an example that toggles fullscreen for the currently active window:

wmctrl -r ':ACTIVE:' -b toggle,fullscreen

For more details on what you can do with this see the man page and for some example see this tutorial.

sinisterstuf

Posted 2017-11-05T20:21:05.953

Reputation: 155