mirror of https://github.com/mum4k/termdash.git
Updated Keyboard API (markdown)
parent
2f69019c8d
commit
dafaeaa6d7
|
@ -13,13 +13,13 @@ The public API surface of this package consists of the following:
|
|||
The **keyboard.Key** type represents keys on the keyboard. The package provides predefined values for some of the keys which can be used directly, e.g:
|
||||
|
||||
```go
|
||||
var key Keyboard
|
||||
var key keyboard.Key
|
||||
key = keyboard.KeyEnter
|
||||
```
|
||||
|
||||
For all other keys like regular letters, the character that represents the letter can be directly assigned to the Key type.
|
||||
|
||||
```go
|
||||
var key Keyboard
|
||||
var key keyboard.Key
|
||||
key = 'a'
|
||||
```
|
Loading…
Reference in New Issue