XFCE
Xfce is a lightweight but powerful desktop environment that will work well on the XO. The following is a tutorial for using Xfce on the XO based on the article from the Free Like GNU article and several forum posts. For a more-integrated Sugar/XFCE experience, see the XFCE and Sugar article.
OrionHi, could you contact me privately? ,
NBC is being left with people that are much better. ,
Screen Brightness/Rotation, Sound Volume, and Battery Status Control
The following method is a simple method using a script. for a more detailed version, see Xfce keybindings for detailed instructions. This script has been reported several times to not work with build 703 or later installed. (Note 1: the problem appears to be a lack of visudo in olpc-sudo. I've gotten it to work by copying a working sudoers file to /etc. This is the file. http://www.filedropper.com/sudoers . (-- link is dead. re-upload please?) I copied the sudoers file before running the script, it may make a difference.)
The keys on your XO can be easily made functional again by installing the rpm on this page: olpc-keybind. This RPM contains the scripts to perform the operations and the instructions to configure your default olpc user account to use them.
This rpm depends on xbindkeys. Because this rpm doesnt yet exist in the official repositry you have to do the following in a terminal (as root) to install it:
yum install xbindkeys rpm -Uhv http://favias.org/sites/favias.org/files/olpc-keybind-1-2.noarch.rpm
To remove this functionality the following command as root in terminal will suffice:
yum remove olpc-keybind xbindkeys
Screen brightness did not initially adjust, as root you have to:
chmod a+rw /sys/class/backlight/dcon-bl/brightness chmod a+rw /sys/class/backlight/dcon-bl/max_brightness
On error 'scriplet failed' run as root /usr/bin/olpc-keybind manually. Run xbindkeys & for testing. If xbindkeys is giving you errors you may need to open olpc-keybind and change all references .xbindkeysrc from "/home/olpc/.xbindkeyssrc" to "/root/.xbindkeysrc". If everything works, add /usr/bin/xbindkeys to Xfce Autostarted Applications via Setting Menue.
Screen rotation does not automatically resize the windows. If you are using fullscreen mode this may be fixed by pressing Alt-F11 twice.
Displaying Battery Status in panel
- Install olpc-keybind rpm for the battery-status binary it provides
- use genmon (see above) to display the battery status in a toolbar
- right-click on a blank spot on an Xfce toolbar, chose Add Item, select Generic Monitor and clicked Add
- right-click the new Generic Monitor item, select Properties, and apply the following settings:
- Command: battery-status
- Label: B
- Period: 300
Another option is to create a small script in /home/olpc called battery.sh (or whatever you would like) with the following line in it:
"echo hal-device | grep charge_level.percentage | sed 's/$/%/' /sys/devices/platform/olpc-battery.0/power_supply/olpc-battery/capacity"
save this script and make sure that the user 'olpc' owns it (chown olpc /home/olpc/battery.sh) and it is executable (chmod +x /home/olpc/battery.sh) Then...
- right-click on a blank spot on an Xfce toolbar, chose Add Item, select Generic Monitor and clicked Add
- right-click the new Generic Monitor item, select Properties, and apply the following settings:
- Command: /home/olpc/battery.sh
- Label: B
- Period: 300
Getting normal fonts for web browsing, xfce desktop
If you think your fonts look a little funny on xfce, you may appreciate more "typical" fonts for your web browser and your desktop. However, this is not entirely "free," but the package itself is distributable for free
- Download the mscorefonts rpm from this website Mscorefonts rpm
- open a terminal as root, in the folder you downloaded the rpm to, and type: rpm -i Micro Pressing tab should auto-complete the file name
- restart your computer.
Alternatively, you could install the Liberation Fonts package. These are non-proprietary, unlike the Microsoft fonts. There are three fonts included which are metrically equivalent to Arial, Times New Roman and Courier New.
The rpm is available here.
Also, you can change your default user interface fonts in the Xfce "User interface settings" and changing the font to a size you recognize. You may set Font DPI to 150. It's also good to turn on anti-aliasing (slight).
Mounting Removable Filesystems
- Insert SD card or usb drive.
- Run thunar, the Xfce File Manager.
- The removable media should appear in the left-hand column. Click on it to mount it. A df will show that it has been mounted in the appropriate place (/mount/VOLUME_NAME)
- To unmount, right click on the media name in the same place and choose unmount.
Change default desktop
Turn Xfce to default desktop
In /home/olpc/
create a copy of .xsession-example
called .xsession
:
#cp /home/olpc/.xsession-example /home/olpc/.xsession
Edit the .xsession
file to launch Xfce on startup:
# nano /home/olpc/.xsession
Find the commented line that reads #exec xterm
- below that line, add the following code:
exec startxfce4
- use CTRL+X to save and exit
- use CTRL+ALT+BACKSPACE to restart X, starting Xfce
Turn back to XO Sugar desktop
To make the original XO Sugar desktop the default boot again, rename the .xsession
file to anything other than .xsession (.xsession.xfce
for instance). Applied changes, e.g. networking, may stay persistent.
Install Sugar/XFCE Control Panel
c-scott has created a script that switches between the XFCE desktop and sugar using the sugar control panel. This works in any joyride build, and the 8.2-760 test build. It comes pre-installed on the faster branch of the joyride build.
Assuming you have xfce installed, next get the gnome icon theme with
yum install gnome-icon-theme
Next, add the sugar-xfce-control
package for a 'desktop switcher' control panel in Sugar. (rpm)
next, add the sugar-mcs-plugin
package to integrate the sugar control panel into XFCE's "Settings Manager". This allows you to switch back from XFCE to Sugar using the same mechanism you use to switch from Sugar to XFCE. ( rpm)
next, add Inherits=gnome
after the [Icon Theme]
line in /usr/share/icons/sugar/index.theme
, so that sugar's theme properly pulls in the gnome filemanager icons
next, add [ -f "$HOME/.xsession-xfce" ] && . "$HOME/.xsession-xfce"
before /usr/bin/ck-xinit-session
in /usr/bin/olpc-session
in order to trigger xfce when it is selected.
The last two steps are easy to mess up. Perhaps the best way to get those changes is to use the files provided in the zip file here: http://www.filedropper.com/xfce-sugarfiles , which also includes the rpms above (Please don't use sites like this for storing files, the files don't exist now). Or you can install the faster build and copy those two files to a usb drive. While you are at it, grab /home/olpc/.xsession-sfce
. Then install the build of your choice, Follow the yum install and RPM install steps, then copy those files from the USB to the appropriate directories.
Trouble?
Defreeze Boot Animation
If you reboot and get stuck at the XO logo (with circle around it), hold down power to shutdown then power up again.
Warning! This is advanced and can potentially screw up your boot. To bypass the boot anim manually, hold down the checkmark while turning the OLPC on, then wait for the machine to tell you to release it.
You can prevent boot freezing by disabling the startup logo animation:
- Open the startup animation logo file
/etc/init.d/0-boot-anim-start
- Above the line saying "# i'm the child", change
if os.fork() == 0:
to
if os.fork() == 'debug':
to prevent the animation code from being executed. Other methods than this one may cause trouble.
XO Wipeout
This document is under continued construction and may contain malicious strategies. In case of major trouble be prepared to wipe out your XO with an USB-Stick. This will clearly erase all data and any changes. Read and understand instructions following Secure Upgrade first, before apply major changes to XO.
Learn Linux
After all, DO NOT forget you are half-blinded low-level hacking a machine designed for the rugged world with a sugared usability for small children... To do that, yes, you have to learn about Linux.
References
See also
- Fedora on XO and Installing Debian as an upgrade to install a conventional desktop Linux distribution on the XO
- OpenBox, a faster window manager with a more complicated install process on the XO.