Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Latest commit

 

History

History
65 lines (47 loc) · 2.17 KB

SDL_keyboard_c.h

File metadata and controls

65 lines (47 loc) · 2.17 KB
 
1
2
/*
SDL - Simple DirectMedia Layer
Jan 24, 2010
Jan 24, 2010
3
Copyright (C) 1997-2010 Sam Lantinga
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 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
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Sam Lantinga
slouken@libsdl.org
*/
#include "SDL_config.h"
#ifndef _SDL_keyboard_c_h
#define _SDL_keyboard_c_h
#include "SDL_keysym.h"
#include "SDL_events.h"
/* Initialize the keyboard subsystem */
extern int SDL_KeyboardInit(void);
May 10, 2010
May 10, 2010
33
34
/* Clear the state of the keyboard */
extern void SDL_ResetKeyboard(void);
Feb 5, 2008
Feb 5, 2008
36
/* Get the default keymap */
Feb 7, 2011
Feb 7, 2011
37
extern void SDL_GetDefaultKeymap(SDL_Keycode * keymap);
Feb 5, 2008
Feb 5, 2008
38
May 10, 2010
May 10, 2010
39
/* Set the mapping of scancode to key codes */
Feb 7, 2011
Feb 7, 2011
40
extern void SDL_SetKeymap(int start, SDL_Keycode * keys, int length);
Feb 5, 2008
Feb 5, 2008
41
Aug 19, 2007
Aug 19, 2007
42
43
44
45
/* Set a platform-dependent key name, overriding the default platform-agnostic
name. Encoded as UTF-8. The string is not copied, thus the pointer given to
this function must stay valid forever (or at least until the call to
VideoQuit()). */
Feb 7, 2011
Feb 7, 2011
46
extern void SDL_SetScancodeName(SDL_Scancode scancode, const char *name);
Aug 19, 2007
Aug 19, 2007
47
48
/* Set the keyboard focus window */
May 10, 2010
May 10, 2010
49
extern void SDL_SetKeyboardFocus(SDL_Window * window);
May 10, 2010
May 10, 2010
51
/* Send a keyboard key event */
Feb 7, 2011
Feb 7, 2011
52
extern int SDL_SendKeyboardKey(Uint8 state, SDL_Scancode scancode);
May 10, 2010
May 10, 2010
54
55
/* Send keyboard text input */
extern int SDL_SendKeyboardText(const char *text);
Sep 19, 2009
Sep 19, 2009
57
/* Send editing text for selected range from start to end */
May 10, 2010
May 10, 2010
58
extern int SDL_SendEditingText(const char *text, int start, int end);
Sep 19, 2009
Sep 19, 2009
59
60
61
62
63
64
65
/* Shutdown the keyboard subsystem */
extern void SDL_KeyboardQuit(void);
#endif /* _SDL_keyboard_c_h */
/* vi: set ts=4 sw=4 expandtab: */