setPrompt method

void setPrompt(
  1. String prompt
)

Updates the prompt shown before the input and repaints the current line.

Implementation

void setPrompt(String prompt) {
  _prompt = prompt;
  _promptWidth = _visibleWidth(prompt);
  if (interactive && !_passthrough) _refresh();
}