mirror of
https://github.com/br0xen/termbox-util.git
synced 2024-11-22 13:33:15 +00:00
Adding Alpha-Numeric Tester
This commit is contained in:
parent
95d2a88a7c
commit
c5ed6dc0ba
@ -23,7 +23,7 @@ const (
|
||||
|
||||
// KeyIsAlphaNumeric Returns whether the termbox event is an
|
||||
// Alpha-Numeric Key Press
|
||||
func KeyIsAlphaNumeric(event termbox.Event) {
|
||||
func KeyIsAlphaNumeric(event termbox.Event) bool {
|
||||
k := event.Ch
|
||||
if (k >= 'a' && k <= 'z') || (k >= 'A' && k <= 'Z') || (k >= '0' && k <= '9') {
|
||||
return true
|
||||
|
Loading…
Reference in New Issue
Block a user