You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my code, I'm continuously calling keyboard.GetKey() in a for loop, taking the resulting character and sending it down a golang channel. It seemed to work very well, however, I accidentally pasted like 10 characters. And the resulting behavior was strange. GetKey() emitted only the first character in the paste string then waited. If I pressed an 11th character on the keyboard, it would emit character number 2 of the originally pasted string. If I clicked 12th character, it would emit the 3rd and so on.
So effectively it has buffered the whole thing and is emitting a character only upon every key press. I would not have expected that. The proper behavior IMO, was for GetKey() to continuously emit keys rapidly until it's out of keys.
Thanks again for the good library
The text was updated successfully, but these errors were encountered:
In my code, I'm continuously calling keyboard.GetKey() in a for loop, taking the resulting character and sending it down a golang channel. It seemed to work very well, however, I accidentally pasted like 10 characters. And the resulting behavior was strange. GetKey() emitted only the first character in the paste string then waited. If I pressed an 11th character on the keyboard, it would emit character number 2 of the originally pasted string. If I clicked 12th character, it would emit the 3rd and so on.
So effectively it has buffered the whole thing and is emitting a character only upon every key press. I would not have expected that. The proper behavior IMO, was for GetKey() to continuously emit keys rapidly until it's out of keys.
Thanks again for the good library
The text was updated successfully, but these errors were encountered: