######################################################################
# Spanish Keyboard file
#
# This is the mapping table for translation of X-symbols
# into DOS key codes and shift states for the Spanish keyboard.
#
# This table is based on the IBM enhanced Spanish keyboard and 
# Sun keyboards.
#   
# When the Spanish keyboard is called for, this table is loaded 
# first. The appropriate Code Page table is then loaded to 
# provide mappings for Xsymbols that do not have representation
# on the keyboard and do appear in the DOS Code Page. This double
# table approach covers use of the Sun keyboard's COMPOSE key
# to generate characters not found on the keyboard.
#  
# The Xsymbols defined in this table  are mapped into the 
# physical location of the appropriate legend on an IBM 102 
# key Enhanced Keyboard. In some cases, the physical location
# followed by a shift state descriptor. This shift state 
# descriptor can be "shift", "Alt Graph", "Caps Lock" and
# "Shift Lock".
# The shift state descriptor is used for a number of things.
#
#  SHIFT: Shift is used when it is necessary to correctly
#         define the DOS legend position for the  Xsymbol 
#         that is being mapped. For example:
#           On the US keyboard the asterisk legend is in 
#           the "shifted position of the key located at 
#           key station 9.
#
#         Shift is also used to assist the keyboard emulation
#         software to distingish between capital and lowercase
#         letters.
#   
#  Alt Graphic: Alt Graphic is shortened to "Alt" in the tables.
#         It is used to inform the emulation software that
#         the key symbol fals in the Alt Graphic location of the
#         key cap.
#
#  Caps Lock: Caps Lock is used to inform the emulator that 
#         the interpretation of the key stroke being mapped
#          can be influenced by the Caps Lock key.
#
#  Shift Lock: Shift Lock is used to inform the emulator that
#         the interpretation of the key stroke being mapped 
#         can be influenced by the shift lock key.
#
# The actual semantics of "shift", "Caps Lock" etc are handled 
# elsewhere.  For example:
#    The meaning of pressing the shift key  and the "A" key
#    while the Caps Lock state is on, is left up to other software.
#
#  
#
# Definitions of shorthand found in the comments::
#
#              shift               shifted key location
#              alt                 Alt Graph key location
#              any                 any shift modifier allowed
#              caps_lock           Caps Lock affected key
#              shift_lock          Shift Lock affected  key
#              CP or cp            Cursor Pad
#              FK of fk            Function Key
#
#              MT or Main Array    Main Typing Array
#              NP or np            Numeric Pad
#
#			##				This definition may lead to problems.
#							It is still being reviewed.
# End of Definitions


######################################################
#
# Generic keyboard functions shared by all keyboards

XK_BackSpace		15	any	# DOS MT Backspace
XK_Tab			16	any
XK_Return		43	any	# DOS MT enter
XK_Pause		126	any	# DOS NP or FK Pause
XK_Scroll_Lock		125	any    # DOS NP or FK Scroll Lock
XK_Escape		110	any
XK_Delete		76	any	# DOS NP Delete 

######################################################################
#
# Cursor control & motion shared by all keyboards

XK_Home			80	any	# NP home see XK_Begin
XK_Left			79	any	# NP left arrow
XK_Up			83	any	# NP up arrow
XK_Right		89	any	# NP right arrow
XK_Down			84	any	# NP down arrow
XK_Prior		85	any	# NP page up
XK_Next			86	any	# NP page down
XK_End			81	any	# NP end
XK_Begin		80	any	## NP home see XK_Home

######################################################################
#
# Specific Function keys shared by all keyboards

XK_Print		124	any	## NP or FK Print Screen
XK_Insert		75	any	# Insert, insert here
XK_Break		126	any	## NP or FK Break (ctrl shift?)
XK_Num_Lock		90	any	# NP or FK Num Lock

#####################################################################
#
# Numeric Keypad numbers and calculator functions shared
# all keyboards

XK_KP_Space		61	any	## MT space bar
XK_KP_Tab		16	any	## map to MT Tab key
XK_KP_Enter		108	any	# NP enter
XK_KP_Equal		11	shift	## map to MT equal sign
XK_KP_Multiply		100	any	# NP asterisk or multiply
XK_KP_Add		106	any	# NP plus
XK_KP_Subtract		105	any	# NP minus
XK_KP_Decimal		104	any	## NP Del key
XK_KP_Divide		95	any	# NP slash

XK_KP_0			99	any	# NP 0
XK_KP_1			93	any	# NP 1
XK_KP_2			98	any	# NP 2
XK_KP_3			103	any	# NP 3
XK_KP_4			92	any	# NP 4
XK_KP_5			97	any	# NP 5
XK_KP_6			102	any	# NP 6
XK_KP_7			91	any	# NP 7
XK_KP_8			96	any	# NP 8
XK_KP_9			101	any	# NP 9

#####################################################################
#
# Generic Function Keys including Sun's numeric pad 
# function keys shared by all keyboards
			
XK_F1			112	any
XK_F2			113	any
XK_F3			114	any
XK_F4			115	any
XK_F5			116	any
XK_F6			117	any
XK_F7			118	any
XK_F8			119	any
XK_F9			120	any
XK_F10			121	any

XK_F11                        
XK_F12 

XK_SunF36		122     any	# keyboard F11 key
XK_SunXK_F36		122    	any	# keyboard F11 key
                       
XK_SunF37		123     any	# keyboard F12 key
XK_SunXK_F37		123     any	# keyboard F12 key

XK_F21			126     any        ## DOS NP or FK pause
XK_R1			126     any        #  DOS NP or FK pause

XK_F22			124     any        ## DOS NP or FK Print Screen
XK_R2			124     any        #  DOS NP or FK Print Screen

XK_F23			125     any        ## DOS NP or FK Scroll Lock
XK_R3			125     any        #  DOS NP or FK Scroll Lock

XK_F24			11       shift       ## DOS NP =
XK_R4			11       shift       #  DOS NP =

XK_F25			95	any	## DOS NP / slash
XK_R5			95	any	#  DOS NP / slash

XK_F26			100	any	## DOS NP * multiply
XK_R6			100	any	#  DOS NP * mulitply

XK_F27			91	any	## DOS NP 7/Home
XK_R7			91	any	#  DOS NP 7/Home

XK_F28			96	any	## DOS NP 8/up arrow
XK_R8			96	any	#  DOS NP 8/up arrow

XK_F29			101	any	## DOS NP 9/Pg Up
XK_R9			101	any	#  DOS NP 9/Pg Up

XK_F30			92	any	## DOS NP 4/left arrow
XK_R10			92	any	#  DOS NP 4/left arrow

XK_F31			97	any	## DOS NP 5
XK_R11			97	any	#  DOS NP 5

XK_F32			102	any	## DOS NP 6/right arrow
XK_R12			102	any	#  DOS NP 6/right arrow

XK_R13			93	any	## DOS NP 1/End
XK_F33			93	any	#  DOS NP 1/End

XK_F34			98	any	## DOS NP 2/down arrow
XK_R14			98	any	#  DOS NP 2/down arrow

XK_F35			103	any	## DOS NP 3/Pg Dn
XK_R15			103	any	#  DOS NP 3/Pg Dn

#####################################################################
#
# Modifiers shared by all keyboards

XK_Shift_L		44 	any	# Leftshift
XK_Shift_R		57 	any	# ightshift
XK_Control_L		58 	any	# Leftcontrol
XK_Control_R		64 	any	# Rightcontrol
XK_Caps_Lock		30 	any	# Capslock
XK_Shift_Lock				# Shiftlock

XK_Meta_R 		#64     any        # Rightmeta / ctrl_R
XK_Mode_switch		62      any        # Rightalt / Alt Graph
XK_Help			112     any  	# might be F1 key in ow2.0  
XK_Alt_L		60	any	# Leftalt
XK_Alt_R		62 	any 	## Rightalt / use for Alt Graph

#####################################################################
#
# Latin1 
XK_Dead_Grave		27
XK_SunFA_Grave		27
XK_SunXK_FA_Grave	27
XK_space		61 	any
XK_exclam		2	shift
XK_quotedbl		3	shift
XK_numbersign		4	alt	
XK_dollar		5	shift
XK_percent		6	shift
XK_ampersand		7	shift
XK_apostrophe		12			## MT apostrophe see XK_quoteright
XK_quoteright		12			## MT apostrophe see XK_apostrophe
XK_parenleft		9	shift
XK_parenright		10	shift
XK_asterisk		28	shift
XK_plus			28			# MT plus
XK_comma		53			# MT comma
XK_minus		55			# MT minus
XK_period		54			# MT period
XK_slash		8	shift	# MT slash
XK_0			11
XK_1			2
XK_2			3
XK_3			4
XK_4			5
XK_5			6
XK_6			7
XK_7			8
XK_8			9
XK_9			10
XK_colon		54	shift
XK_semicolon		53	shift
XK_less			45			# MT left angle bracket
XK_equal		11	shift
XK_greater		45	shift	# MT right angle bracket
XK_question		12	shift
XK_at			3	alt	     # MT @-sign
XK_A			31	shift caps
XK_B			50	shift caps
XK_C			48	shift caps
XK_D			33	shift caps
XK_E			19	shift caps
XK_F			34	shift caps
XK_G			35	shift caps
XK_H			36	shift caps
XK_I			24	shift caps
XK_J			37	shift caps
XK_K			38	shift caps
XK_L			39	shift caps
XK_M			52	shift caps
XK_N			51	shift caps
XK_O			25	shift caps
XK_P			26	shift caps
XK_Q			17	shift caps
XK_R			20	shift caps
XK_S			32	shift caps
XK_T			21	shift caps
XK_U			23	shift caps
XK_V			49	shift caps
XK_W			18	shift caps
XK_X			47	shift caps
XK_Y			22	shift caps
XK_Z			46	shift caps
XK_bracketleft		27	alt		## MT square bracket
XK_backslash		1	alt		#  MT backslash
XK_bracketright		28	alt		## MT square bracket
XK_Dead_Circum		27	shift
XK_SunFA_Circum		27	shift
XK_SunXK_FA_Circum	27	shift
XK_asciicircum			## Spacing and non-spacing
XK_underscore		55	shift
XK_grave					# MT spacing and non-spacing
XK_quoteleft					## Filled by Code Page table
XK_a			31	caps
XK_b			50	caps
XK_c			48	caps
XK_d			33	caps
XK_e			19	caps
XK_f			34	caps
XK_g			35	caps
XK_h			36	caps
XK_i			24	caps
XK_j			37	caps
XK_k			38	caps
XK_l			39	caps
XK_m			52	caps
XK_n			51	caps
XK_o			25	caps
XK_p			26	caps
XK_q			17	caps
XK_r			20	caps
XK_s			32	caps
XK_t			21	caps
XK_u			23	caps
XK_v			49	caps
XK_w			18	caps
XK_x			47	caps
XK_y			22	caps
XK_z			46	caps
XK_braceleft		41	alt		## MT curly bracket
XK_bar			2	alt		## MT vertical bar
XK_braceright		42	alt		## MT curly bracket
XK_asciitilde					# MT spacing and non-spacing

##############################################################
# 
# 8-bit characters and symbols

         
XK_nobreakspace	
XK_exclamdown		13			# upside down exclamation
XK_cent			
XK_sterling					# U.K. pound sterling
XK_currency			
XK_yen			
XK_brokenbar		
XK_section					# Paragraph, section
XK_diaeresis		41	shift	# spacing and non-spacing
XK_SunFA_Diaeresis		41	shift	# spacing and non-spacing
XK_SunXK_FA_Diaeresis		41	shift	# spacing and non-spacing
XK_copyright		
XK_ordfeminine		1	shift	# underscore a
XK_guillemotleft				# DOS left double angle 
XK_notsign		7	alt		# Logical Not Sign
XK_hyphen		
XK_registered		
XK_macron		
XK_degree			
XK_plusminus		
XK_twosuperior					# superscript 2
XK_threesuperior				# superscript 3
XK_acute		41			# spacing and non-spacing
XK_SunFA_Acute		41			# spacing and non-spacing
XK_SunXK_FA_Acute	41			# spacing and non-spacing
XK_mu						## note XK_greek_mu also
XK_paragraph					# Pilcrow
XK_periodcentered	4	alt		# Centered dot
XK_cedilla		
XK_onesuperior	
XK_masculine		1			# Masculine ordinal, underscore o
XK_guillemotright				# Right angle quotation mark
XK_onequarter		
XK_onehalf		
XK_threequarters	
XK_questiondown	13	shift
XK_Agrave		
XK_Aacute		
XK_Acircumflex		
XK_Atilde		
XK_Adiaeresis		
XK_Aring			
XK_AE			
XK_Ccedilla		42	shift caps	
XK_Egrave		
XK_Eacute			
XK_Ecircumflex		
XK_Ediaeresis		
XK_Igrave			
XK_Iacute		
XK_Icircumflex		
XK_Idiaeresis		
XK_ETH			
XK_Eth			 
XK_Ntilde		40	shift caps			
XK_Ograve		
XK_Oacute		
XK_Ocircumflex		
XK_Otilde		
XK_Odiaeresis		
XK_multiply		
XK_Ooblique		
XK_Ugrave		
XK_Uacute		
XK_Ucircumflex		
XK_Udiaeresis		
XK_ssharp						#  small German sharp s
XK_agrave			
XK_aacute			
XK_acircumflex	
XK_atilde			
XK_adiaeresis		
XK_aring			
XK_ae			
XK_ccedilla		42	caps
XK_egrave			
XK_eacute			
XK_ecircumflex		
XK_ediaeresis		
XK_igrave			
XK_iacute			
XK_icircumflex		
XK_idiaeresis		
XK_eth			
XK_ntilde		40	caps
XK_ograve			
XK_oacute			
XK_ocircumflex		
XK_otilde			
XK_odiaeresis		
XK_division		
XK_oslash			
XK_ugrave			
XK_uacute			
XK_ucircumflex		
XK_udiaeresis		
XK_yacute			
XK_thorn		
XK_ydiaeresis		

K_Greek_mu				## note 
