Limiting the number of characters of a user input
opened this issue · comments
Hello everyone, I've been using blessed for a few weeks now but am not sure if it's possible to limit the number of characters a user can input. If not, any ideas?
I think you're asking for a limited field input?
Like for example, a username field accepting only 10 characters?
Yes this is possible, but not directly. blessed does not provide these "high level" interfaces, but you can certainly build one yourself on top of blessed!
I just came across a new downstream project doing just that, perhaps you could contribute https://github.com/thomasballinger/simplerepl
@lovemac15 I'm interested in answering these kind of questions at the project jquast linked to, raise an issue there and I'd be happy to talk you through implementing this or add an example of it to that project.
Thank you guys very much!