Monday, February 16, 2015

xorg odds and ends, xorg.conf

xterm settings

In Arch it's become slightly difficult to implement xterm settings. The way Xorg initializes has changed -- it no longer directly loads .Xdefaults or .Xresources. Instead, they are called by .xinitrc. Sometimes, this extra step fails and your xterm will look vanilla. The correct .xinitrc lines calling .Xresources should already be present, and should look something like...
$ nano .xinitrc
if [ -f "$userresources" ]; then

xrdb -merge "$userresources"

fi
Troubleshoot: save either .Xresources or .Xdefaults. I kept .Xresources and therefore deleted .Xdefaults, but I could have switched this. Add your xterm customizations to whichever of the two is kept. Check these customizations by loading the file directly...
$ xrdb .Xresources
...then open a new xterm to see if it looks configured. I typically make modifications of color, clipboard availability, and so forth, eg...
$ nano .Xresources
XTerm*selectToClipboard:true
... but this can also be added to one's command to open xterm in their icewm menu.

If xterm was modified, .Xresources is being called by .xinitrc. However if xterm looks unmodified, then either .xinitrc needs modification to properly call .Xresources or, .Xresources requires further work.

xorg install order

  1. # pacman xf86-video-ati There are several drivers to pick from; you'll need the correct one for your chip. I found my chip this way:
    $ lspci |grep vga
    VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] RS780MC [Mobility Radeon HD 3100]
    So I had the Radeon HD 3100 RS780MC chip, which corresponded with the xf86-video-ati driver. Since it's radeon, I also proceeded with the next step; others may not need it
  2. # nano /etc/mkinitcpio.conf
      MODULES="radeon"
    # mkinitcpio -p linux
    # reboot
  3. # pacman xorg-xinit xorg-server xorg-server-utils xorg-apps (80Mb)
  4. # pacman icewm icewm-themes (20Mb) just get some WM in there to test all the settings
  5. # pacman dillo a light browser for looking stuff up about the install
  6. get the skeletons for /etc/X11/xinit/xinitrc, /usr/share/icewm (the entire directory, then chown it and change it to ".icewm"), and /etc/dillo/dillorc
  7. modify ~/.xinitrc to add "exec icewm"
  8. I like to reboot here, before starting X, but some might just logout and log back in. Either way, "startx", and then tweak and add apps

xorg.conf

x configuration is a persisting mystery. The following may help in Arch.
  1. the files to configure 90% of your X session are in /etc/X11/xorg.conf.d/ directory
  2. create /etc/X11/xorg.conf.d/10-extras.conf for your custom stuff, like screen blanking, Blender mouse remapping, and so on -- all in one file
  3. the config files can have multiple "ServerLayout", "InputDevice", etc. sections
  4. comments in configuration files in the directory are with pound sign "#"
  5. .xinitrc and .Xresources play about a 10% role
  6. /etc/profile.d/locale.sh is important for "locales", which affect font encoding. You want all of these to be "C"

No comments: