###################
## SERVER LAYOUT ##
###################

Section "ServerLayout"
    Identifier  "Simple Layout"
		Screen			0 "Screen0" 0 0
		Screen			1	"Screen1" 0 0
    InputDevice "Mouse1" 				"CorePointer"
    InputDevice "Keyboard1" 		"CoreKeyboard"
#    InputDevice	"stylus"    		"SendCoreEvents"
    Screen      "Screen1"
    Option			"BlankTime" 		"2"
    Option			"StandbyTime" 	"3"
    Option			"SuspendTime" 	"4"
    Option			"OffTime" 			"5"
EndSection

############
## MODULE ##
############

Section "Module"
    Load    "dbe"
    Load    "extmod"
    Load    "glx"
    Load    "type1"
    Load    "freetype"
    
    SubSection "extmod"
        Option    "omit xfree86-dga"
    EndSubSection
EndSection

Section "DRI"
    Mode 0666
EndSection


###########
## FILES ##
###########

Section "Files"
    FontPath 	"/usr/share/fonts/100dpi"
    FontPath 	"/usr/share/fonts/75dpi"
    FontPath 	"/usr/share/fonts/TTF"
    FontPath 	"/usr/share/fonts/Type1"
    FontPath 	"/usr/share/fonts/corefonts"
    FontPath 	"/usr/share/fonts/cyrillic"
    FontPath 	"/usr/share/fonts/freefonts"
    FontPath 	"/usr/share/fonts/misc"
    FontPath 	"/usr/share/fonts/sharefonts"
    FontPath 	"/usr/share/fonts/ukr"
    FontPath	"/usr/share/fonts/dejavu"
EndSection


##############
## KEYBOARD ##
##############

Section "InputDevice"
    Identifier  "Keyboard1"
    Driver      "keyboard"
    Option 			"AutoRepeat"	"500 30"
    Option 			"XkbRules"		"xorg"
    Option 			"XkbModel"    "logicdo"
    Option 			"XkbLayout"   "us,cz_qwerty"
    Option 			"XkbOptions"  "grp:ctrls_toggle,grp_led:caps,ctrl:nocaps"
EndSection

###########
## MOUSE ##
###########

Section "InputDevice"
    Identifier	"Mouse1"
    Driver			"mouse"
    Option 			"Protocol"    		"ImPS/2"
    Option 			"Device"      		"/dev/input/mice"
    Option 			"ZAxisMapping" 		"4 5"
    Option 			"Emulate3Buttons" "true"
EndSection

############
## TABLET ##
############

#Section "InputDevice"
#	Driver        "wacom"
#	Identifier    "stylus"
##	Option        "Device"        "/dev/ttyS0"          # SERIAL ONLY
#	Option        "Device"        "/dev/input/event4"   # USB ONLY
#	Option        "Type"          "stylus"
#	Option        "USB"           "on"                  # USB ONLY
##	Option        "ForceDevice"   "ISDV4"               # Tablet PC ONLY
#EndSection

#############
## MONITOR ##
#############

Section "Monitor"
    Identifier  "lcd"
		#HorizSync   45-70
		#VertRefresh 60-100
    Option	"DPMS"
    Option "ReducedBlanking"
EndSection

Section "Monitor"
		Identifier	"televize"
		#HorizSync		30-50
		#VertRefresh	60
		Option "ModeValidation" "NoDFPNativeResolutionCheck"
		HorizSync 28-84
		Vertrefresh	43-60
		ModeLine "1080i" 74.52 1920 1952 2016 2208 1080 1084 1096 1126 -hsync -vsync interlace
EndSection

##############
## GRAPHICS ##
##############

Section "Device" # sekce pro LCD
    Identifier  "nVidia"
    Driver      "nvidia"
		BusID				"PCI:1:0:0"
		Screen			0
    Option			"NvAGP"				"2"
    Option			"RenderAccel"	"true"
    Option			"DPMS"				"1"
    Option			"NoLogo"			"1"
    Option			"AddARGBGLXVisuals"
    Option			"aiglx"				"true"
    Option			"UseEvents"		"false"
    Option 			"CustomEDID" 	"DFP-0:/usr/local/nvidia/edid.bin"
EndSection
Section "Device" # sekce pro TV
    Identifier  "nVidiaTV"
    Driver      "nvidia"
		BusID				"PCI:1:0:0"
		Screen			1
    Option			"NvAGP"				"2"
    Option			"RenderAccel"	"true"
    Option			"DPMS"				"1"
    Option			"NoLogo"			"1"
    Option			"AddARGBGLXVisuals"
    Option			"aiglx"				"true"
    Option			"UseEvents"		"false"
#    Option 			"CustomEDID" 	"DFP-1:/home/kreuz/edid_panasonic.bin"
    #Option "ModeValidation" "NoEdidModes"
		Option "ExactModeTimingsDVI" "TRUE"
		Option "UseEDIDFreqs" "False"
		Option "UseEvents" "True"
		Option "UseEdidDpi" "FALSE"
		Option "ModeValidation" "NoWidthAlignmentCheck, NoDFPNativeResolutionCheck"
EndSection

Section "Extensions"
	Option	"Composite"	"enable"
EndSection

############
## SCREEN ##
############

Section "Screen"
    Identifier  "Screen0"
    Monitor     "lcd"
    Device      "nVidia"
    DefaultDepth 24

    Subsection "Display"
        Depth       8
        Modes       "1280x1024" "1024x768" "800x600"
        ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       16
        Modes       "1280x1024" "1024x768" "800x600"
        ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       24
        Modes       "1920x1200" "1280x1024" "1024x768" "800x600"
        ViewPort    0 0
    EndSubsection
		Option			"ConnectedMonitor"	"DFP-0,DFP-1"
		Option			"UseDisplayDevice"	"DFP-0"
EndSection

Section "Screen"
		Identifier		"Screen1"
		Device				"nVidiaTV"
		Monitor				"televize"
		DefaultDepth 	24
		SubSection "Display"
			Viewport	0 0
			Depth			24
			Modes			"1080i" "1920x1080" "1024x768" "800x600" "640x480"
    EndSubsection
		Option				"TVStandard"				"HD1080i"
		Option				"TVOutFormat"				"COMPONENT"
		Option				"ConnectedMonitor"	"DFP-0,DFP-1"
		Option				"UseDisplayDevice"	"DFP-1"
		Option "TVOverScan" "0.7"
		Option "ExactModeTimingsDVI" "True" 
EndSection
