Function SDL_SetScancodeName

pub unsafe extern "C" fn SDL_SetScancodeName(
    scancode: SDL_Scancode,
    name: *const i8,
) -> bool
Available on crate feature dep_sdl3 only.
Expand description

Set a human-readable name for a scancode.

§Parameters

  • scancode: the desired SDL_Scancode.
  • name: the name to use for the scancode, encoded as UTF-8. The string is not copied, so the pointer given to this function must stay valid while SDL is being used.

§Return value

Returns true on success or false on failure; call SDL_GetError() for more information.

§Thread safety

This function is not thread safe.

§Availability

This function is available since SDL 3.2.0.

§See also