Wiki Page Content

Differences between revisions 13 and 14
Revision 13 as of 2011-04-25 20:01:41
Size: 1307
Editor: SheenaSmith
Comment: update content - w/ Matt, Sam (in progress)
Revision 14 as of 2011-04-25 20:13:25
Size: 1252
Editor: SheenaSmith
Comment: update content - w/ Matt (+Sam); remove draft
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
||<tablewidth="100%" style="color: #FF0000;" :> DRAFT||
Line 23: Line 22:
[[SDL_KeyboardEvent]] is a member of the [[SDL_Event]] union and is used when an event of type SDL_KEYDOWN or SDL_KEYUP is reported. You would access it through the event's key field. [[SDL_KeyboardEvent]] is a member of the [[SDL_Event]] union and is used when an event of type SDL_KEYDOWN or SDL_KEYUP is reported. You would access it through the event's `key` field.

SDL_KeyboardEvent

A structure that contains keyboard button event information.

Data Fields

Uint32

type

the event type; SDL_KEYDOWN or SDL_KEYUP

Uint32

windowID

the window with keyboard focus, if any

Uint8

state

the state of the key; SDL_PRESSED or SDL_RELEASED

Uint8

repeat

non-zero if this is a key repeat

SDL_Keysym

keysym

the SDL_Keysym representing the key that was pressed or released

Code Examples

You can add your code example here

Remarks

SDL_KeyboardEvent is a member of the SDL_Event union and is used when an event of type SDL_KEYDOWN or SDL_KEYUP is reported. You would access it through the event's key field.

An SDL_KEYDOWN or SDL_KEYUP event occurs whenever a user presses or releases a button on a keyboard. The information on what key was pressed or released is in the keysym member.


CategoryStruct, CategoryEvents

None: SDL_KeyboardEvent (last edited 2014-01-05 19:47:03 by PhilippWiesemann)

(Page Info.)
Feedback
Please include your contact information if you'd like to receive a reply.
Submit