Monday, August 29, 2011

How to change to LXDM and Openbox in OpenSuSE

If you like really minimalistic desktop environment you can try LX Desktop Manager and Openbox as your Window Manager. Here you'll find out how to configure all the necessary things.


First you need to install lxdm and openbox. These should be in standard repositories. As root run:
zypper in lxdm lxcc openbox
Now edit the file /etc/sysconfig/displaymanager and change DISPLAYMANAGER="lxdm", or you can change this value via yast2 in etc/sysconfig editor > Desktop > Display manager > DISPLAYMANAGER > set value to lxdm. Now you have lxdm as your default desktop manager.
Tip: to disable autologin go to yast2 > User and Group Administration > Expert Options > Login Settings > unselect autologin

Now create .xinitrc file in your home directory and add line exec openbox-session into it.
Copy the configuration files for openbox
mkdir -p ~/.config/openbox
cp /etc/xdg/openbox/autostart.sh ~/.config/openbox/
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/

cp /etc/xdg/openbox/menu.xml ~/.config/openbox/

Add startup programs at the bottom of autostart.sh (remember to add & to each startup entry so it'll be launched in the background).

Adding panel:
I use tint2 as my default panel.
zypper in tint2
-remember to add tint2 & to autostart.sh file

Now you can reboot and choose openbox as your session in the login window.

CONFIGURATION:
OPENBOX:
To configure openbox run obconf. To change keyboard shortcuts and other settings see ~/.config/openbox/rc.xml file. Here are some interesting options:
ADD logout, shutdown and reboot to the openbox menu.
To add new entries to the menu edit file menu.xml and add following to the menu section:
<item label="Log Out">
    <action name="Execute">
      <prompt>
            Are you sure you want to logout?
      </prompt>
      <execute>
        sudo killall X
      </execute>
    </action>
  </item>

<item label="Reboot">
    <action name="Execute">
        <prompt>
            Are you sure you want to reboot?
        </prompt>
        <execute>
            sudo /sbin/shutdown -r now
        </execute>
    </action>
</item>

<item label="Shutdown">
    <action name="Execute">
        <prompt>
            Are you sure you want to shutdown?
        </prompt>
        <execute>
            sudo /sbin/shutdown -h now
        </execute>
    </action>
</item>

Note that you have to add shutdown and killall to the sudoers.

LXDM:
To configure LXDM run lxcc. Here you can change only few things as the most of LXDE tool are not installed. Here you can setup the LXDE Settings
Advanced settings:
see file /etc/lxdm/lxdm.conf
and /usr/share/lxdm/themes/ -here you can customize your login screen, copy the Industrial theme and edit settings in greeter.ui file. Change theme in lxcc > LXDM Settings, or /usr/sbin/lxdmconf (as root)

BACKGROUND:
To set your background install feh from repositories or from software.opensuse.org
To apply your wallpaper: feh --bg-center /path/to/wallpaper.jpg (for more options see man feh).
You can add this to your startup configuration file.

tint2 PANEL:
tint2 panel configuration is stored in ~/.config/tint2
You can use tintwizard.py command to configure tint2 panel or do it manually by editing the file tint2rc.

No comments:

Post a Comment