-->
Previous Table of Contents Next


Understanding the XF86Config Sections

The XF86Config file is a normal ASCII text file read by XFree86 and used to configure the X server to run properly under your hardware system. The file is formatted into the following sections, as shown in Table 21.4.

Table 21.4 XF86Config File Sections

Section Description

Files Lists directories for the font and rgb files.
ServerFlags Specifies special flags for the X server.
Keyboard Describes the type of keyboard.
Pointer Describes your pointing device, typically your mouse.
Monitor Provides detailed descriptions about your monitor. This section is very important because incorrect information can severely damage the monitor.
Device Describes your video card.
Screen Uses the information from the Monitor and Device sections to describe your physical screen area, including such items as number of colors and size of the screen in pixels.

Each section in the file has the following general form:


Section “Namedata entry values

data entry values

more values as needed…

#this is a comment line and is ignored by XFree86

EndSection

You should build such a configuration file using a text editor such as vi, following the examples given. After creating the file, you run the xf86Config program to generate an XF86Config file for comparison. Finally, you run the X server in a special mode to probe for your system’s settings, which you may not be able to determine from the examples, the generated file, or the documentation. These precautions are necessary because of the real threat of damage to your system.


See “Using vi,” p. 181

The Files Section

This section lists the various fonts installed on your system in the /usr/X11R6/lib/X11/fonts directory. Each font series will have its own subdirectory here, so you can use the following command to determine which ones are loaded:


ls /usr/X11R6/lib/X11/fonts

Each directory listed should have a corresponding entry in the Files section.

Depending on your selections during installation, your font files should go into standard directories, and your Files section will appear as in the sample section here:


Section “Files”

RgbPath    “/usr/X11R6/lib/X11/rgb”

fontPath   “/usr/X11R6/lib/X11/misc/”

fontPath   “/usr/X11R6/lib/X11/Type1/”

fontPath   “/usr/X11R6/lib/X11/speedo/”

fontPath   “/usr/X11R6/lib/X11/75dpi/”

fontPath   “/usr/X11R6/lib/X11/100dpi/”

EndSection

The ServerFlags Section

You’ll rarely need to edit the default ServerFlags section. This section controls the following three flags used by the X server to control its operation.

Flag Description
NoTrapSignals An advance flag that causes the X server to “dump core”—create a debugging file—when an operating system software signal is received by the X server
DontZap Disables the use of the <Ctrl-Alt-Backspace> key combination to terminate the X server
DontZoom Disables switching between various graphics modes

The sample section is shown as follows with each flag commented out and thus disabled:


Section “ServerFlags”

#NoTrapSignals

#DontZap

#DontZoom

EndSection

The Keyboard Section

The Keyboard section lets you specify several options for your keyboard, such as key mappings. The minimal Keyboard section looks like this:


Section “Keyboard”

Protocol “Standard”

AutoRepeat 500 5

ServerNumLock

EndSection

Many more options are available, as shown in Table 21.5, but many aren’t required for proper operation of your keyboard. Type man XF86Config at a shell prompt to see a full description of the various parameters for each section of the XF86Config file.

Table 21.5 Keyboard Section Options

Option Parameter/Description

Protocol Is Standard or Xqueue (Standard is the default)
AutoRepeat delay rate Sets the delay before repeating the key at the specified rate
ServerNumLock Tells the X server to handle the response to the NumLock key internally
VTSysReq Specifies that the X server will handle switching between virtual terminals by using the <SysRq> key instead of the <Ctrl> key

Typically, you use the <Alt-Fx> method to switch between the various virtual terminals under Linux (where Fx indicates any function key). But when in X, you must use <Ctrl-Alt-Fx> to access the virtual terminal. Of course, if you’re questioning the need for virtual terminals when running a GUI, consider what happens if your X session locks—you can then use a virtual terminal to kill your X session.


See “Logging In,” p. 338

The Pointer Section

The Pointer section deals with your mouse or other pointing device. XFree86 uses the information here to configure your mouse for use under X. Minimally, you should specify the protocol used by your mouse and the device type. If you have a serial mouse, the device will be the serial port used by the mouse. A sample Pointer section follows:


Section “Pointer”

Protocol    “Microsoft”

Device      “/dev/mouse”

EndSection

The various protocols supported by Linux are

BusMouse Microsoft
Logitech Mouse Systems
MM Series Xqueue
Mouseman PS/2


Previous Table of Contents Next