1 2 3 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 33 34 35 36 37 38 39 40
|
.\" Automatically generated by Pandoc 1.19.2.4
.\"
.TH "al_clear_keyboard_state" "3" "" "Allegro reference manual" ""
.hy
.SH NAME
.PP
al_clear_keyboard_state \- Allegro 5 API
.SH SYNOPSIS
.IP
.nf
\f[C]
#include\ <allegro5/allegro.h>
void\ al_clear_keyboard_state(ALLEGRO_DISPLAY\ *display)
\f[]
.fi
.SH DESCRIPTION
.PP
Clear the state of the keyboard, emitting ALLEGRO_EVENT_KEY_UP(3) for
each currently pressed key.
The given display is regarded as the one which had the keyboard focus
when the event occurred.
In case display is NULL no event is emitted.
For most keyboard drivers Allegro maintains its own state of the
keyboard, which might get out of sync with the real one.
This function is intended to remedy such situation by resetting
Allegro\[aq]s keyboard state to a known default (no key pressed).
This is particularly useful in response to
ALLEGRO_EVENT_DISPLAY_SWITCH_OUT(3) events.
.SH SEE ALSO
.PP
al_get_keyboard_state(3), ALLEGRO_KEYBOARD_STATE(3)
.SH SINCE
.PP
5.2.3
.RS
.PP
\f[I][Unstable API]:\f[] This is a new feature and the exact semantics
are still being decided upon.
.RE
|