---
title: GCKeyboardInput
framework: gamecontroller
role: symbol
role_heading: Class
path: gamecontroller/gckeyboardinput
---

# GCKeyboardInput

A controller profile that uses the keyboard as the input device.

## Declaration

```swift
class GCKeyboardInput
```

## Overview

Overview Use this profile to get the state of the keyboard buttons that the GCKeyCode structure defines.

## Topics

### Getting Change Information

- [keyChangedHandler](gamecontroller/gckeyboardinput/keychangedhandler.md)
- [GCKeyboardValueChangedHandler](gamecontroller/gckeyboardvaluechangedhandler.md)

### Accessing Buttons

- [isAnyKeyPressed](gamecontroller/gckeyboardinput/isanykeypressed.md)
- [button(forKeyCode:)](gamecontroller/gckeyboardinput/button(forkeycode:).md)
- [GCKeyCode](gamecontroller/gckeycode.md)
- [Keycode Constants](gamecontroller/keycode-constants.md)

## Relationships

### Inherits From

- [GCPhysicalInputProfile](gamecontroller/gcphysicalinputprofile.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Accessing controller profiles

- [extendedGamepad](gamecontroller/gccontroller/extendedgamepad.md)
- [GCPhysicalInputProfile](gamecontroller/gcphysicalinputprofile.md)
- [GCMouseInput](gamecontroller/gcmouseinput.md)
- [GCExtendedGamepad](gamecontroller/gcextendedgamepad.md)
- [GCDualShockGamepad](gamecontroller/gcdualshockgamepad.md)
- [GCXboxGamepad](gamecontroller/gcxboxgamepad.md)
- [GCDualSenseGamepad](gamecontroller/gcdualsensegamepad.md)
- [microGamepad](gamecontroller/gccontroller/microgamepad.md)
- [GCMicroGamepad](gamecontroller/gcmicrogamepad.md)
- [GCDirectionalGamepad](gamecontroller/gcdirectionalgamepad.md)
- [motion](gamecontroller/gccontroller/motion.md)
- [physicalInputProfile](gamecontroller/gccontroller/physicalinputprofile.md)
- [gamepad](gamecontroller/gccontroller/gamepad.md)
