SLiM: From Login to Desktop

Article 4 of 6
SLiM: From Login to Desktop

After a Successful Login

After a successful login, SLiM hands control to the command configured in slim.conf: exec /bin/bash -login /etc/X11/Xsession %session

That command invokes the system’s X session script, passing along the selected session value. In simplified form, the transfer looks like this:
SLiM → login_cmd → /etc/X11/Xsession → startxfce4 → Xfce desktop

Where %session Comes From

The F1 shortcut can select a session definition. The Exec line from that definition replaces %session in the launch command.

On out-of-the-box BcalcOS, there’s only one definition, so the substitution happens automatically: %session → startxfce4

Put together, the completed command becomes:
exec /bin/bash -login /etc/X11/Xsession startxfce4

Finding the Xfce Session

BcalcOS provides an Xfce session definition at: /usr/share/xsessions/xfce.desktop

Its important entries:
Name=Xfce Session
Exec=startxfce4
DesktopNames=XFCE

Name supplies the session’s displayed name. Exec is the line SLiM borrows for %session. DesktopNames identifies the desktop environment.

The startxfce4 command starts the Xfce session, which brings up the panel, menus, settings tools, and window manager.

SLiM’s role is to hand the selected session its cue.

The Login Theme Is Not the Desktop Theme

SLiM’s login theme controls the appearance of the login screen. It’s selected through current_theme in /etc/slim.conf. BcalcOS uses desktop-slim-theme, located under: /usr/share/slim/themes/

That directory contains slim.theme and the image assets used to draw the login screen.

Xfce’s appearance settings are somewhere else entirely. Changing your Xfce wallpaper does not change the login screen, and installing a different SLiM theme does not redecorate the desktop.

They belong to different stages of the graphical experience.

Key Takeaway

A successful login ends SLiM’s part of the job. The selected session definition supplies the command, and the system’s X session script takes it from there.


Next: Troubleshooting Common Problems