What is Xfce?

Xfce is a Desktop Environment, like GNOME or KDE. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit, and contains its own development environment (libraries, daemons, etc), similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware.

Why use Xfce?

Here is a (subjective) list of reasons to use Xfce:

It's fast, faster than the other major DEs.

It's stable. In the long time Xfce-4 has been out, only a small handful of bugs has been discovered, despite it having a rather large following.

It's pretty. It uses GTK2 and is themable. You can make Xfce look very nice. The fonts are completely AA as well.

It works great with multiple monitors. Xfce's Xinerama support is the best out of any WM/DE, IMO.

It doesn't get in your way. You'll find Xfce helps your work flow, rather than always making itself "present."

It comes with a built-in compositor which allows for true transparency among other cool things.

Why not use Xfce?

Here is a (subjective) list of reasons not to use Xfce:

Doesn't contain all the features and integration of the major DEs.

Slower development cycle.

Because it's based on the CDE design, the layout may not be as familiar.

How to Install Xfce

The Xfce source and documentation are available at http://www.xfce.org/. But since you're using ArchLinux, you can grab Xfce from Pacman.

Xfce is modular. That means there is no need for you to run every part, you can pick and choose. Because of this, Xfce has a bunch of Arch packages.

To install the base Xfce system, run:

# pacman -S xfce4

If you want extras, like panel plugins and extra themes, run this:

# pacman -S xfce4-goodies gtk2-themes-collection

If you want to be able to play sound files, you should also install ESD, which acts as the Xfce sound daemon. (Or you can install xfmedia, the default Xfce media player, and it will pull ESD as a dependency.)

# pacman -S esd

If you want to admire 'Tips and Tricks' on login, you must install the fortune-mod package:

# pacman -S fortune-mod

Running Xfce

There are two ways to run Xfce. One is the "automatic" method. To start Xfce from the console, you can simply run:

# startxfce4

Note: startxfce4 sets DPI to 96 by default, so font sizes will be different than when starting from .xinitrc.

To customize the Xfce startup using this method, you could copy /etc/xdg/xfce4/xinitrc to $HOME/.xfce4, and edit that file
To add programs to the startup up using this method, add symlinks from the programs you want to $HOME/Desktop/Autostart.

If you want more control over what starts and your initial settings, you can add these items to your $HOME/.xinitrc (leaving out and adding what you want):

xfce-mcs-manager
xfwm4 --daemon
xfdesktop &
exec xfce4-panel

or

exec xfce4-session

How To Use Xfce With DMs

As of Xfce 4.2.0, the Arch packages add the proper session files for Xfce. They are contained in the xfce-utils package, which should be installed with a base installation. Simply Enable a DM.

How to shutdown and reboot from Xfce

Make sure that DBus and HAL are enabled in the DAEMONS line in /etc/rc.conf. Then add your normal user to the power group:

# gpasswd -a USER power

Note: This group is only used by HAL, so you still need root privileges for shutting down the system via command line (halt/poweroff/shutdown).

Tips

Commands for the settings manager

There is no official documentation for the commands executed. One must look at .desktop files /usr/share/applications/ folder. For the people who like to know exactly what is happening, here is a handy list to save the effort:

To review all the available setting manager commands run the following in a terminal:

$ grep xfce-setting-show /usr/share/applications/xfce*settings*

How to enable the compositor in Xfce 4.4

Xfce 4.4 comes with a builtin compositor adding the option for fancy window effects, shadows and transparency and so on.

You can find it in Settings->Window manager tweaks. But if it isn't there, take the following steps:

Open up $HOME/.config/xfce4/mcs_settings/wmtweaks.xml, and ensure that <option name="Xfwm/UseCompositing" type="int" value="1"/> is present. If the wmtweaks file is not there, open up the Settings->Window manager tweaks and change some things, then close it, and the file should appear.

Make sure the following lines are in your /etc/X11/xorg.conf file:

Section "Extensions"
Option "Composite" "Enable"
EndSection

Finally, restart X and the compositor should be available.

Why doesn't my desktop refresh?

Xfce 4.4 uses FAM (File Alteration Monitor) to get notification when a file or directory changes.
Don't forget to add 'fam' to the list of DAEMONS in /etc/rc.conf

Use a transparent background for desktop icon titles

To change the default white background of desktop icon titles to something more suitable, edit the .gtkrc-2.0 file in your home directory and add the following (create the file if needed):

How to customize starting xfce

This includes getting necessary environment variables into the GUI runtime.

Copy the file /etc/xdg/xfce4/xinitrc to ~/.config/xfce4/

Edit this file. For example, you can add something like this somehwere in the middle:

source $HOME/.bashrc

# start rxvt-unicode server

urxvtd -q -o -f

How to add themes to XFCE

1. First go to xfce-look.org
I don't know the difference between a GTK GTK2 or XFCE theme, so I choose XFCE theme.
Look around for a theme you want and click "Download".

2. Go to the directory where you downloaded the tarball/file and extract it using Squeeze/Xarchiver/CLI.

3. I'm sure there is another way to do it, but I usually go to Terminal and type: "sudo thunar"

4. A root thunar window appears and I copy the file[s] extracted and put them inside /usr/share/themes (i.e. if the theme is called abc, there will be a folder called "abc" inside).
Inside /usr/share/themes/abc, there is a folder that you create called xfwm4 that will contain whatever files that is included with that theme.
An alternative would be to put then in your home folder in ~/.themes. If it doesn't exist, create it. Should be done as normal user, not root [I think].

How to remove menu entries from the System menu

With the built-in menu editor, you cannot remove menu entries from the System menu.
Here’s how:
1) Go to the /usr/share/applications folder. Copy and paste in the terminal (Xfce menu > System > Terminal):
cd /usr/share/applications
2) This folder should be full of .desktop files. To see how many there are, type

ls

Say the one you want to edit is Firefox. Copy and paste into the terminal:

sudo mousepad firefox.desktop

3) In the bottom of the file, paste the following:

NoDisplay=true

Save and exit. Now Firefox won’t show up in the System menu. You can do this with any program.
--Anonymo 02:19, 8 August 2008 (EDT)

But what do you do with menu entries which do not show up in /usr/share/applications (e.g., apps installed via wine)?

I've found some shortcuts that shows in the category “Other” (that wine is using) in this directory:
~/.local/share/applications/wine/
--Anonymo 02:19, 8 August 2008 (EDT)