# XF86Config-4 (XFree86 X Window System server configuration file)
#
#   dpkg-reconfigure xserver-xfree86 will remake this file
#
#  CUSTOM CONFIGURED FOR NETBOOK TOUCHSCREEN AND EXTERNAL MOUSE

Section "Files"
#	FontPath	"unix/:7100"			# local font server
	# if the local font server has problems, we can fall back on these
	FontPath	"/usr/lib/X11/fonts/misc"
#	FontPath	"/usr/lib/X11/fonts/cyrillic"
#	FontPath	"/usr/lib/X11/fonts/100dpi/:unscaled"
	FontPath	"/usr/lib/X11/fonts/75dpi/:unscaled"
#	FontPath	"/usr/lib/X11/fonts/Type1"
#	FontPath	"/usr/lib/X11/fonts/CID"
#	FontPath	"/usr/lib/X11/fonts/Speedo"
#	FontPath	"/usr/lib/X11/fonts/100dpi"
	FontPath	"/usr/lib/X11/fonts/75dpi"
EndSection

Section "Module"
#	Load	"GLcore"
#	Load	"bitmap"
#	Load	"dbe"
#	Load	"ddc"
#	Load	"dri"
	Load	"extmod"
#	Load	"freetype"
#	Load	"glx"
#	Load	"int10"
#	Load	"record"
#	Load	"speedo"
#	Load	"type1"
#	Load	"vbe"
EndSection

Section "Modes"
   Identifier "Modes[0]"
# Standard VESA mode
#   Modeline "640x480" 25.175 640 664 760 800 480 491 493 525
# Mode given by "fbset -x" 
   Modeline "640x480" 4.131 640 642 645 647 480 480 484 484 +hsync +vsync
EndSection

Section "InputDevice"
	Identifier	"Generic Keyboard"
	Driver		"keyboard"
	Option          "AutoRepeat" "250 30"
	Option		"CoreKeyboard"
#	Option		"XkbRules"	"xfree86"
#	Option		"XkbModel"	"pc104"
#	Option		"XkbLayout"	"us"
EndSection

Section "InputDevice"
	Identifier	"Configured Mouse"
	Driver		"mouse"
#	Option		"CorePointer"
	Option		"Device"		"/dev/ttyS0"
	Option		"Protocol"		"microsoft"
	Option		"Emulate3Buttons"	"true"
	Option		"ZAxisMapping"		"4 5"
EndSection

Section "InputDevice"
     Identifier "Touchscreen"
     Driver "summa"
     Option  "Device" "/dev/tscreen"
     Option "Mode" "absolute"
#    Option "Cursor" "stylus"
# Other options that might be useful
# Compatible  (driver is now compatible enough to not need this)
# Resolution, XSize, YSize, XOffset, YOffset
EndSection

Section "Device"
	Identifier	"Generic Video Card"
	Driver		"fbdev"
	Option		"UseFBDev"		"true"
        Option          "ShadowFB"  "false"
#        Option          "Rotate" "CW"
EndSection

Section "Monitor"
	Identifier	"Generic Monitor"
#	HorizSync	28-33
#	VertRefresh	43-72
        UseModes       "Modes[0]"
	Option		"DPMS"
EndSection

Section "Screen"
	Identifier	"Default Screen"
	Device		"Generic Video Card"
	Monitor		"Generic Monitor"
	DefaultDepth	8
	SubSection "Display"
		Depth		8
		Modes		"640x480"
	EndSubSection
EndSection

Section "ServerFlags"
       Option "AllowMouseOpenFail"
       Option "RandR" "off"
EndSection

Section "ServerLayout"
	Identifier	"Default Layout"
	Screen		"Default Screen"
	InputDevice	"Generic Keyboard"
#  Configured Mouse to /dev/ttyS0 
	InputDevice	"Configured Mouse" "SendCoreEvents"
        InputDevice     "Touchscreen" "CorePointer"
        Option          "Xinerama" "off"
#	InputDevice	"Generic Mouse"
EndSection

#Section "DRI"
#	Mode	0666
#EndSection