5

Under LXDE desktop manager Alt+F11 can be used to switch a program to full screen.

I use this shortcut so often that'd I rather have certain programs always open in full screen instead of doing it manually.

Is it possible to define some system configuration, or a shell script that'd always launch particular programs in full screen? (Particular not all because I wouldn't want certain small windows like network configuration window and system calendar to open in full screen).

TPS
  • 2,483
  • 5
  • 27
  • 45
Kshitiz Sharma
  • 8,585
  • 21
  • 59
  • 75

2 Answers2

6

Put this in your ~/.config/openbox/lubuntu-rc.xml in between <applications> tags:

<application class="Firefox" name="Navigator">
    <fullscreen>yes</fullscreen>
</application>

To get specific class or name for your applications, use this:

obxprop | grep '^_OB_APP'

and then click with your cursor inside the app window.


Useful website: http://openbox.org/wiki/Help:Configuration

MichalH
  • 2,309
  • 1
  • 14
  • 29
  • Running obxprop gives me `_OB_APP_CLASS(UTF8_STRING) = "lxpanel" _OB_APP_NAME(UTF8_STRING) = "panel"`. Not `firefox` and `Navigator` as you've specified. – Kshitiz Sharma Jul 22 '15 at 13:02
  • @KshitizSharma did you click inside firefox window after running `obxprop`? – MichalH Jul 22 '15 at 15:18
  • No. I was clicking on the firefox taskbar entry. Directly clicking inside the window works correctly. – Kshitiz Sharma Jul 23 '15 at 09:40
  • However, after entering it into `lubuntu-rc.xml` it only works for `firefox`. Entries for `sublime text` and `chrome` don't result in full screen. Is it working for you? – Kshitiz Sharma Jul 23 '15 at 09:41
  • Yes, it works. Here is an example snippet of the file: http://pastebin.com/Grb3Yehs – MichalH Jul 24 '15 at 09:17
  • +1 I can confirm that this works. But it has a catch. For some programs it's making every window in the program as full screen. For example, in sublime text I'm getting the save file dialog as full screen. – Kshitiz Sharma Jul 27 '15 at 10:13
  • @KshitizSharma you can add more specifications, this works for my sublime text: `` – MichalH Jul 27 '15 at 11:09
2

Generally lxde will have a rc.xml/lxde-rc.xml/lubuntu-rc.xml inside ~/.config/openbox/

Example contents of the xml file:

<application name="firefox">
  <fullscreen>true</fullscreen>
</application>

You should add the following line under your preferred application node (as shown above in the example):

 <fullscreen>true</fullscreen>

And execute openbox --reconfigure

neuron
  • 1,941
  • 11
  • 20