I am writing a small text application using curses on Linux.
I use the curses functions to enter the keyboard. Key auto-retries work, for example. if I hold the key down, I get a few key events until I release the key again.
Is it also possible to distinguish between real-key events and those generated by the key repetition logic?
Background: the application is a small data entry interface in which the user can change integers of certain parameters. Ultimately, the application will work without a standard keyboard. I will have only four buttons for entering data: “increase”, “decrease”, “ok” and “cancel”.
Since the ranges of numbers are large, I would like to know if the user holds the key. If he does, I can quickly scan my number range without increasing my number by one, but by 10 or maybe 100. If the user wears out the key, the input method should be accurate again and just increase / decrease the numbers by one.
Is this possible with cursive keyboard input functions?
source share