在ThinkPad T23上使用Slackware Linux

--设置XWindows及鼠标

Author:Cherife Li

什么是X Window

X Window系统(X11或X)是一种位图显示的视窗系统。它是在Unix和类Unix操作系统,以及OpenVMS上建立图形用户界面的标准工具包和协议,并可用于几乎所有的现代操作系统。
X 为 GUI 环境提供了基本的框架:在屏幕上绘图和移动窗口,以及与鼠标和键盘的互动。X 并没有管辖到使用者接口 —这是由每个独立的程序处理。因为如此,以 X 为基础环境的视觉样式变化非常地多;不同的程序可能彻底地展现不同的接口。
X 以 "网络通透性" 为特色:应用程序("客户端" 应用程序)所执行的机器,不一定是使用者本地的机器(显示的 "服务器")。X 的"客户端"和"服务器"字眼的使用是人们经常预期的相反,"服务器" 是使用者本地的显示而不是远程的机器。
X 在 1984年起始于 MIT。现在的协议版本,X11,是在1987年9月所释出的。该专案是由 X.Org 基金会所领导;现在的参考实作是版本 11 release 6.8.2,且在MIT 执照和相似的表示许可执照下是自由软件。

简单描述一下,更多详情可以参考:

http://www.x.org/
http://www.linuxdevcenter.com/pub/a/linux/2005/08/25/whatisXwindow.html
http://wiki.ccw.com.cn/X_Window
http://linux.vbird.org/linux_basic/0590xwindow.php

我的设置

下面是我的/etc/X11/xorg.conf文件的设置,这样的设置在我的T23上工作的很好,1400×1050@75HZ的分辨率,TrackPoint(中键滚屏),USB鼠标都正常工作。
		# **********************************************************************
# Module section -- this section is used to specify
# which dynamically loadable modules to load.
# **********************************************************************
#
Section "Module"

# This loads the DBE extension module.
Load "dbe" # Double buffer extension

# This loads the miscellaneous extensions module, and disables
# initialisation of the XFree86-DGA extension within that module.

SubSection "extmod"
Option "omit xfree86-dga" # don't initialise the DGA extension
EndSubSection

# This loads the font modules
Load "type1"
Load "freetype"
#Load "speedo"

# This loads the GLX module
Load "glx" # OpenGL X protocol interface
Load "GLcore" # OpenGL support
Load "dri" # Direct rendering infrastructure
Load "extmod" # Misc. required extensions
Load "v4l" # Video4Linux
# Load "pex5" # PHIGS for X 3D environment (obsolete)
# Load "record" # X event recorder
# Load "xie" # X Image Extension (obsolete)

EndSection

# **********************************************************************
# Files section. This allows default font and rgb paths to be set
# **********************************************************************

Section "Files"

# The location of the RGB database. Note, this is the name of the
# file minus the extension (like ".txt" or ".db"). There is normally
# no need to change the default.

RgbPath "/usr/X11R6/lib/X11/rgb"

# Multiple FontPath entries are allowed (which are concatenated together),
# as well as specifying multiple comma-separated entries in one FontPath
# command (or a combination of both methods)
#
# If you don't have a floating point coprocessor and emacs, Mosaic or other
# programs take long to start up, try moving the Type1 and Speedo directory
# to the end of this list (or comment them out).
#

FontPath "/usr/X11R6/lib/X11/fonts/local/"
FontPath "/usr/X11R6/lib/X11/fonts/misc/"
FontPath "/usr/X11R6/lib/X11/fonts/75dpi/:unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/100dpi/:unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/Type1/"
FontPath "/usr/X11R6/lib/X11/fonts/CID/"
FontPath "/usr/X11R6/lib/X11/fonts/Speedo/"
FontPath "/usr/X11R6/lib/X11/fonts/75dpi/"
FontPath "/usr/X11R6/lib/X11/fonts/100dpi/"
FontPath "/usr/X11R6/lib/X11/fonts/cyrillic/"
FontPath "/usr/X11R6/lib/X11/fonts/TTF/"

# ModulePath can be used to set a search path for the X server modules.
# The default path is shown here.

# ModulePath "/usr/X11R6/lib/modules"

EndSection

# **********************************************************************
# Input devices
# **********************************************************************

# **********************************************************************
# Core keyboard's InputDevice section
# **********************************************************************

Section "InputDevice"

Identifier "Keyboard1"
Driver "kbd"
Option "CoreKeyboard"
Option "XkbRules" "xfree86"
Option "XkbLayout" "us"
EndSection


# **********************************************************************
# Core Pointer's InputDevice section
# **********************************************************************

Section "InputDevice"

# Identifier and driver

Identifier "Trackpoint"
Driver "mouse"
Option "CorePoint"
Option "Device" "/dev/input/mouse0"
Option "Protocol" "ExplorerPS/2"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "on"
Option "Emulate3Timeout" "50"
Option "EmulateWheel" "on"
Option "EmulateWheelButton" "2"
Option "EmulateWheelTimeOut" "200"
Option "YAxisMapping" "4 5"
Option "XAxisMapping" "6 7"
EndSection
Section "InputDevice"
Identifier "USBMouse"
Driver "mouse"
Option "SendCoreEvents" "true"
Option "Device" "/dev/input/mice"
Option "Protocol" "IMPS/2"
Option "Buttons" "5"
Option "ZAxisMapping" "4 5"
EndSection

# **********************************************************************
# Monitor section
# **********************************************************************

# Any number of monitor sections may be present

Section "Monitor"

Identifier "My Monitor"

# HorizSync is in kHz unless units are specified.
# HorizSync may be a comma separated list of discrete values, or a
# comma separated list of ranges of values.
# NOTE: THE VALUES HERE ARE EXAMPLES ONLY. REFER TO YOUR MONITOR'S
# USER MANUAL FOR THE CORRECT NUMBERS.

HorizSync 31.5 - 90
VertRefresh 59-100
Option "DPMS"
EndSection


# **********************************************************************
# Graphics device section
# **********************************************************************

# Any number of graphics device sections may be present

Section "Device"
Identifier "VESA Framebuffer"
# Driver "vesa"
Driver "savage"
VideoRam 16384 #4096
# Insert Clocks lines here if appropriate
EndSection

# **********************************************************************
# Screen sections
# **********************************************************************

# Any number of screen sections may be present. Each describes
# the configuration of a single screen. A single specific screen section
# may be specified from the X server command line with the "-screen"
# option.
Section "Screen"
Identifier "Screen 1"
Device "VESA Framebuffer"
Monitor "My Monitor"
# HorizSync 31.5-75.0
# VertRefresh 40.0-90.0
# Option "DPMS"
# Modeline "1024x768_60.00" 94.39 1024 1088 1200 1376 768 769 772 807 -HSync +Vsync
# If your card can handle it, a higher default color depth (like 24 or 32)
# is highly recommended.

# DefaultDepth 8
# DefaultDepth 16
DefaultDepth 24
# DefaultDepth 32
SubSection "Display"
Depth 16
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 24
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 32
Modes "1400x1050"
EndSubSection
EndSection

# **********************************************************************
# ServerLayout sections.
# **********************************************************************

# Any number of ServerLayout sections may be present. Each describes
# the way multiple screens are organised. A specific ServerLayout
# section may be specified from the X server command line with the
# "-layout" option. In the absence of this, the first section is used.
# When now ServerLayout section is present, the first Screen section
# is used alone.

Section "ServerLayout"

# The Identifier line must be present
Identifier "Simple Layout"

# Each Screen line specifies a Screen section name, and optionally
# the relative position of other screens. The four names after
# primary screen name are the screens to the top, bottom, left and right
# of the primary screen. In this example, screen 2 is located to the
# right of screen 1.

Screen "Screen 1"

# Each InputDevice line specifies an InputDevice section name and
# optionally some options to specify the way the device is to be
# used. Those options include "CorePointer", "CoreKeyboard" and
# "SendCoreEvents".

InputDevice "Trackpoint" "CorePointer"
InputDevice "Keyboard1" "CoreKeyboard"
InputDevice "USBMouse" "SendCoreEvents"
EndSection

Section "DRI"
Mode 0666
EndSection

The End.

Valid XHTML & CSS|©2008 dOtImes.cOm, All rights reserved.|Creative Commons|Linux on Laptops| TuxMobil|Firefox
Google™ Powered
Posted and Maintained by Cherife Li
Last Update: Sunday, 2007-10-07, 1:11, GMT+0800.