3 replaced http://unix.stackexchange.com/ with https://unix.stackexchange.com/
source | link

Following the template of another stack useranother stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Update

A wmctrl solution remains elusive. However xdotool and a bashscript can toggle any application in a single command, which can then be bound to a key.

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Update

A wmctrl solution remains elusive. However xdotool and a bashscript can toggle any application in a single command, which can then be bound to a key.

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Update

A wmctrl solution remains elusive. However xdotool and a bashscript can toggle any application in a single command, which can then be bound to a key.

2 added 226 characters in body; edited title
source | link

Focusing a keyboard Keyboard-bound applicationapplications in Openbox

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Update

A wmctrl solution remains elusive. However xdotool and a bashscript can toggle any application in a single command, which can then be bound to a key.

Focusing a keyboard-bound application in Openbox

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Keyboard-bound applications in Openbox

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.

Update

A wmctrl solution remains elusive. However xdotool and a bashscript can toggle any application in a single command, which can then be bound to a key.

1
source | link

Focusing a keyboard-bound application in Openbox

Following the template of another stack user I've bound a keyboard shortcut to toggle an application between hidden and fullscreen. The only problem is, no matter what application I apply it to, I have to manually focus it after it pops up. Here's the relevant portions of my config:

<keybind key="F10">
  <action name="Execute">
    <execute>wmctrl -x gvim -a gvim.alwayson -b toggle,fullscreen,hidden</execute>
  </action>
</keybind>
...
<application name="gvim"
             class="alwayson">
  <focus>yes</focus>
  <maximized>true</maximized>
  <decor>no</decor>
  <skip_taskbar>yes</skip_taskbar>
</application>

I've played with all the relevant-seeming openbox actions and wmctrl flags.