Closed zee-bit closed 3 years ago
Thanks, released as 0.13
@rr- Thanks for the merge - I also think this could be good upstream depending on the activity there, though would still need integration here in terms of the other commands like paste?
Unfortunately I don't understand the question. BTW @neiljp I invited you as a collaborator. Later on we can think of a way to let you publish new versions through GitHub actions.
@rr- I meant whether this feature belongs in urwid.Edit
or similar, as a max-length could be a more fundamental property. However, I'm not sure how active upstream urwid
is, or if they'd accept it - and urwid-readline
would still need to handle situations like the paste case that is specific to this library.
There may be several use-cases, where you want to restrict the user input into a
ReadlineEdit
widget to not go beyond a particular limit, this PR makes it possible for clients to specify amax_char
argument when initializing aReadlineEdit
widget so that the user can't input text beyond that limit. In particularzulip-terminal
has such a use-case, where it needsReadlineEdit
widgets for stream and topic to only accept input up to 60 characters.Relevant discussion: