-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Labels
Description
Read me
Read this first before creating an issue:
- do not use this issue tracker to ask questions, instead use one of these channels. Questions will likely be closed without notice.
- you shall create a feature request only when it is general purpose enough.
- make sure that the feature is not already
Describe the feature
Allow enable/disable echoing input characters back to the remote client.
Use cases
This allows temporarily disabling echo, for example to input a password, without replacing echoHandler and losing built-in readline functionality.
Contribution
Proposed implementation in TermImpl.java:
- Add a new class field:
private boolean echoOn = true;
- Add an if block in the constructor:
echoHandler = codePoints -> {
// Echo
if (echoOn) {
echo(codePoints);
}
readline.queueEvent(codePoints);
};
- Add a setter:
public void setEchoOn(boolean echoOn) {
this.echoOn = echoOn;
}