;; /*
;;     SDL - Simple DirectMedia Layer
;;     Copyright (C) 1997, 1998, 1999, 2000, 2001  Sam Lantinga
;; 
;;     This library is free software; you can redistribute it and/or
;;     modify it under the terms of the GNU Library General Public
;;     License as published by the Free Software Foundation; either
;;     version 2 of the License, or (at your option) any later version.
;; 
;;     This library is distributed in the hope that it will be useful,
;;     but WITHOUT ANY WARRANTY; without even the implied warranty of
;;     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
;;     Library General Public License for more details.
;; 
;;     You should have received a copy of the GNU Library General Public
;;     License along with this library; if not, write to the Free
;;     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
;; 
;;     Sam Lantinga
;;     slouken@devolution.com
;; */
;; 
;; #ifdef SAVE_RCSID
;; static char rcsid =
;;  "@(#) $Id: SDL_keysym.lsh,v 1.1 2002/08/19 07:04:08 profshadoko Exp $";
;; #endif
;; 
;; #ifndef _SDL_keysym_h
;; #define _SDL_keysym_h
;; 
;; /* What we really want is a mapping of every raw key on the keyboard.
;;    To support international keyboards, we use the range 0xA1 - 0xFF
;;    as international virtual keycodes.  We'll follow in the footsteps of X11...
;;    The names of the keys
;;  */
;;  
;; typedef enum {
;; 	/* The keyboard syms have been cleverly chosen to map to ASCII */

#? SDL_Keysym
;; each keyboard symbol is associated with a constant whose
;; symbolic name represents the key, and value represents
;; the key code (generally the ASCII code of the character).
;; Key symbols are of the form SDLK_0, SDLK_A, SDLK_b, SDLK_SPACE,
;; etc.... Look into sdl/SDL_keysym.lsh for a complete list.
(libload "libc/constants")

(defconstant "SDLK_UNKNOWN"		 0)
(defconstant "SDLK_FIRST"		 0)
(defconstant "SDLK_BACKSPACE"		 8)
(defconstant "SDLK_TAB"		 9)
(defconstant "SDLK_CLEAR"		 12)
(defconstant "SDLK_RETURN"		 13)
(defconstant "SDLK_PAUSE"		 19)
(defconstant "SDLK_ESCAPE"		 27)
(defconstant "SDLK_SPACE"		 32)
(defconstant "SDLK_EXCLAIM"		 33)
(defconstant "SDLK_QUOTEDBL"		 34)
(defconstant "SDLK_HASH"		 35)
(defconstant "SDLK_DOLLAR"		 36)
(defconstant "SDLK_AMPERSAND"		 38)
(defconstant "SDLK_QUOTE"		 39)
(defconstant "SDLK_LEFTPAREN"		 40)
(defconstant "SDLK_RIGHTPAREN"		 41)
(defconstant "SDLK_ASTERISK"		 42)
(defconstant "SDLK_PLUS"		 43)
(defconstant "SDLK_COMMA"		 44)
(defconstant "SDLK_MINUS"		 45)
(defconstant "SDLK_PERIOD"		 46)
(defconstant "SDLK_SLASH"		 47)
(defconstant "SDLK_0"			 48)
(defconstant "SDLK_1"			 49)
(defconstant "SDLK_2"			 50)
(defconstant "SDLK_3"			 51)
(defconstant "SDLK_4"			 52)
(defconstant "SDLK_5"			 53)
(defconstant "SDLK_6"			 54)
(defconstant "SDLK_7"			 55)
(defconstant "SDLK_8"			 56)
(defconstant "SDLK_9"			 57)
(defconstant "SDLK_COLON"		 58)
(defconstant "SDLK_SEMICOLON"		 59)
(defconstant "SDLK_LESS"		 60)
(defconstant "SDLK_EQUALS"		 61)
(defconstant "SDLK_GREATER"		 62)
(defconstant "SDLK_QUESTION"		 63)
(defconstant "SDLK_AT"			 64)
;; 	/* 
;; 	   Skip uppercase letters
;; 	 */
(defconstant "SDLK_LEFTBRACKET"	 91)
(defconstant "SDLK_BACKSLASH"		 92)
(defconstant "SDLK_RIGHTBRACKET"	 93)
(defconstant "SDLK_CARET"		 94)
(defconstant "SDLK_UNDERSCORE"		 95)
(defconstant "SDLK_BACKQUOTE"		 96)
(defconstant "SDLK_a"			 97)
(defconstant "SDLK_b"			 98)
(defconstant "SDLK_c"			 99)
(defconstant "SDLK_d"			 100)
(defconstant "SDLK_e"			 101)
(defconstant "SDLK_f"			 102)
(defconstant "SDLK_g"			 103)
(defconstant "SDLK_h"			 104)
(defconstant "SDLK_i"			 105)
(defconstant "SDLK_j"			 106)
(defconstant "SDLK_k"			 107)
(defconstant "SDLK_l"			 108)
(defconstant "SDLK_m"			 109)
(defconstant "SDLK_n"			 110)
(defconstant "SDLK_o"			 111)
(defconstant "SDLK_p"			 112)
(defconstant "SDLK_q"			 113)
(defconstant "SDLK_r"			 114)
(defconstant "SDLK_s"			 115)
(defconstant "SDLK_t"			 116)
(defconstant "SDLK_u"			 117)
(defconstant "SDLK_v"			 118)
(defconstant "SDLK_w"			 119)
(defconstant "SDLK_x"			 120)
(defconstant "SDLK_y"			 121)
(defconstant "SDLK_z"			 122)
(defconstant "SDLK_DELETE"		 127)
;; 	/* End of ASCII mapped keysyms */
;; 
;; 	/* International keyboard syms */
(defconstant "SDLK_WORLD_0"		 160) ;		/* 0xA0 *
(defconstant "SDLK_WORLD_1"		 161)
(defconstant "SDLK_WORLD_2"		 162)
(defconstant "SDLK_WORLD_3"		 163)
(defconstant "SDLK_WORLD_4"		 164)
(defconstant "SDLK_WORLD_5"		 165)
(defconstant "SDLK_WORLD_6"		 166)
(defconstant "SDLK_WORLD_7"		 167)
(defconstant "SDLK_WORLD_8"		 168)
(defconstant "SDLK_WORLD_9"		 169)
(defconstant "SDLK_WORLD_10"		 170)
(defconstant "SDLK_WORLD_11"		 171)
(defconstant "SDLK_WORLD_12"		 172)
(defconstant "SDLK_WORLD_13"		 173)
(defconstant "SDLK_WORLD_14"		 174)
(defconstant "SDLK_WORLD_15"		 175)
(defconstant "SDLK_WORLD_16"		 176)
(defconstant "SDLK_WORLD_17"		 177)
(defconstant "SDLK_WORLD_18"		 178)
(defconstant "SDLK_WORLD_19"		 179)
(defconstant "SDLK_WORLD_20"		 180)
(defconstant "SDLK_WORLD_21"		 181)
(defconstant "SDLK_WORLD_22"		 182)
(defconstant "SDLK_WORLD_23"		 183)
(defconstant "SDLK_WORLD_24"		 184)
(defconstant "SDLK_WORLD_25"		 185)
(defconstant "SDLK_WORLD_26"		 186)
(defconstant "SDLK_WORLD_27"		 187)
(defconstant "SDLK_WORLD_28"		 188)
(defconstant "SDLK_WORLD_29"		 189)
(defconstant "SDLK_WORLD_30"		 190)
(defconstant "SDLK_WORLD_31"		 191)
(defconstant "SDLK_WORLD_32"		 192)
(defconstant "SDLK_WORLD_33"		 193)
(defconstant "SDLK_WORLD_34"		 194)
(defconstant "SDLK_WORLD_35"		 195)
(defconstant "SDLK_WORLD_36"		 196)
(defconstant "SDLK_WORLD_37"		 197)
(defconstant "SDLK_WORLD_38"		 198)
(defconstant "SDLK_WORLD_39"		 199)
(defconstant "SDLK_WORLD_40"		 200)
(defconstant "SDLK_WORLD_41"		 201)
(defconstant "SDLK_WORLD_42"		 202)
(defconstant "SDLK_WORLD_43"		 203)
(defconstant "SDLK_WORLD_44"		 204)
(defconstant "SDLK_WORLD_45"		 205)
(defconstant "SDLK_WORLD_46"		 206)
(defconstant "SDLK_WORLD_47"		 207)
(defconstant "SDLK_WORLD_48"		 208)
(defconstant "SDLK_WORLD_49"		 209)
(defconstant "SDLK_WORLD_50"		 210)
(defconstant "SDLK_WORLD_51"		 211)
(defconstant "SDLK_WORLD_52"		 212)
(defconstant "SDLK_WORLD_53"		 213)
(defconstant "SDLK_WORLD_54"		 214)
(defconstant "SDLK_WORLD_55"		 215)
(defconstant "SDLK_WORLD_56"		 216)
(defconstant "SDLK_WORLD_57"		 217)
(defconstant "SDLK_WORLD_58"		 218)
(defconstant "SDLK_WORLD_59"		 219)
(defconstant "SDLK_WORLD_60"		 220)
(defconstant "SDLK_WORLD_61"		 221)
(defconstant "SDLK_WORLD_62"		 222)
(defconstant "SDLK_WORLD_63"		 223)
(defconstant "SDLK_WORLD_64"		 224)
(defconstant "SDLK_WORLD_65"		 225)
(defconstant "SDLK_WORLD_66"		 226)
(defconstant "SDLK_WORLD_67"		 227)
(defconstant "SDLK_WORLD_68"		 228)
(defconstant "SDLK_WORLD_69"		 229)
(defconstant "SDLK_WORLD_70"		 230)
(defconstant "SDLK_WORLD_71"		 231)
(defconstant "SDLK_WORLD_72"		 232)
(defconstant "SDLK_WORLD_73"		 233)
(defconstant "SDLK_WORLD_74"		 234)
(defconstant "SDLK_WORLD_75"		 235)
(defconstant "SDLK_WORLD_76"		 236)
(defconstant "SDLK_WORLD_77"		 237)
(defconstant "SDLK_WORLD_78"		 238)
(defconstant "SDLK_WORLD_79"		 239)
(defconstant "SDLK_WORLD_80"		 240)
(defconstant "SDLK_WORLD_81"		 241)
(defconstant "SDLK_WORLD_82"		 242)
(defconstant "SDLK_WORLD_83"		 243)
(defconstant "SDLK_WORLD_84"		 244)
(defconstant "SDLK_WORLD_85"		 245)
(defconstant "SDLK_WORLD_86"		 246)
(defconstant "SDLK_WORLD_87"		 247)
(defconstant "SDLK_WORLD_88"		 248)
(defconstant "SDLK_WORLD_89"		 249)
(defconstant "SDLK_WORLD_90"		 250)
(defconstant "SDLK_WORLD_91"		 251)
(defconstant "SDLK_WORLD_92"		 252)
(defconstant "SDLK_WORLD_93"		 253)
(defconstant "SDLK_WORLD_94"		 254)
(defconstant "SDLK_WORLD_95"		 255) ;		/* 0xFF *
;; 
;; 	/* Numeric keypad */
(defconstant "SDLK_KP0"		 256)
(defconstant "SDLK_KP1"		 257)
(defconstant "SDLK_KP2"		 258)
(defconstant "SDLK_KP3"		 259)
(defconstant "SDLK_KP4"		 260)
(defconstant "SDLK_KP5"		 261)
(defconstant "SDLK_KP6"		 262)
(defconstant "SDLK_KP7"		 263)
(defconstant "SDLK_KP8"		 264)
(defconstant "SDLK_KP9"		 265)
(defconstant "SDLK_KP_PERIOD"		 266)
(defconstant "SDLK_KP_DIVIDE"		 267)
(defconstant "SDLK_KP_MULTIPLY"	 268)
(defconstant "SDLK_KP_MINUS"		 269)
(defconstant "SDLK_KP_PLUS"		 270)
(defconstant "SDLK_KP_ENTER"		 271)
(defconstant "SDLK_KP_EQUALS"		 272)
;; 
;; 	/* Arrows + Home/End pad */
(defconstant "SDLK_UP"			 273)
(defconstant "SDLK_DOWN"		 274)
(defconstant "SDLK_RIGHT"		 275)
(defconstant "SDLK_LEFT"		 276)
(defconstant "SDLK_INSERT"		 277)
(defconstant "SDLK_HOME"		 278)
(defconstant "SDLK_END"		 279)
(defconstant "SDLK_PAGEUP"		 280)
(defconstant "SDLK_PAGEDOWN"		 281)
;; 
;; 	/* Function keys */
(defconstant "SDLK_F1"			 282)
(defconstant "SDLK_F2"			 283)
(defconstant "SDLK_F3"			 284)
(defconstant "SDLK_F4"			 285)
(defconstant "SDLK_F5"			 286)
(defconstant "SDLK_F6"			 287)
(defconstant "SDLK_F7"			 288)
(defconstant "SDLK_F8"			 289)
(defconstant "SDLK_F9"			 290)
(defconstant "SDLK_F10"		 291)
(defconstant "SDLK_F11"		 292)
(defconstant "SDLK_F12"		 293)
(defconstant "SDLK_F13"		 294)
(defconstant "SDLK_F14"		 295)
(defconstant "SDLK_F15"		 296)
;defconstant "state modifier" keys */
(defconstant "SDLK_NUMLOCK"		 300)
(defconstant "SDLK_CAPSLOCK"		 301)
(defconstant "SDLK_SCROLLOCK"		 302)
(defconstant "SDLK_RSHIFT"		 303)
(defconstant "SDLK_LSHIFT"		 304)
(defconstant "SDLK_RCTRL"		 305)
(defconstant "SDLK_LCTRL"		 306)
(defconstant "SDLK_RALT"		 307)
(defconstant "SDLK_LALT"		 308)
(defconstant "SDLK_RMETA"		 309)
(defconstant "SDLK_LMETA"		 310)
(defconstant "SDLK_LSUPER"		 311) ;		/* Left "Windows" key *
(defconstant "SDLK_RSUPER"		 312) ;		/* Right "Windows" key *
(defconstant "SDLK_MODE"		         313) ;		/* "Alt Gr" key *
(defconstant "SDLK_COMPOSE"		 314) ;		/* Multi-key compose key *
;defconstant "function keys" */
(defconstant "SDLK_HELP"		 315)
(defconstant "SDLK_PRINT"		 316)
(defconstant "SDLK_SYSREQ"		 317)
(defconstant "SDLK_BREAK"		 318)
(defconstant "SDLK_MENU"		 319)
(defconstant "SDLK_POWER"		 320) ;		/* Power Macintosh power key *
(defconstant "SDLK_EURO"		 321) ;		/* Some european keyboards *
;; 
;; 	/* Add any other keys here */
;; 
(defconstant "SDLK_LAST" 322)
;; } SDLKey;
;; 
;; /* Enumeration of valid key mods (possibly OR'd together) */
;; typedef enum {
(defconstant "KMOD_NONE"   0x0000)
(defconstant "KMOD_LSHIFT" 0x0001)
(defconstant "KMOD_RSHIFT" 0x0002)
(defconstant "KMOD_LCTRL"  0x0040)
(defconstant "KMOD_RCTRL"  0x0080)
(defconstant "KMOD_LALT"   0x0100)
(defconstant "KMOD_RALT"   0x0200)
(defconstant "KMOD_LMETA"  0x0400)
(defconstant "KMOD_RMETA"  0x0800)
(defconstant "KMOD_NUM"    0x1000)
(defconstant "KMOD_CAPS"   0x2000)
(defconstant "KMOD_MODE"   0x4000)
(defconstant "KMOD_RESERVED"  0x800)
;; } SDLMod;
;; 
(defconstant "KMOD_CTRL"	(+ @@KMOD_LCTRL @@KMOD_RCTRL))
(defconstant "KMOD_SHIFT"	(+ @@KMOD_LSHIFT @@KMOD_RSHIFT))
(defconstant " KMOD_ALT"	(+ @@KMOD_LALT @@KMOD_RALT))
(defconstant " KMOD_META"	(+ @@KMOD_LMETA @@KMOD_RMETA))
;; 
;; #endif /* _SDL_keysym_h */
