mirror of
https://github.com/rust-lang/rustlings.git
synced 2024-12-25 23:10:30 +00:00
Fix displaying the list message in narrow mode
This commit is contained in:
parent
bfa00ffbdc
commit
dbbeb7d4ed
1 changed files with 5 additions and 2 deletions
|
@ -263,14 +263,17 @@ impl<'a> ListState<'a> {
|
||||||
}
|
}
|
||||||
|
|
||||||
writer.write_ascii(b" | <q>uit list")?;
|
writer.write_ascii(b" | <q>uit list")?;
|
||||||
|
next_ln(stdout)?;
|
||||||
} else {
|
} else {
|
||||||
writer.stdout.queue(SetForegroundColor(Color::Magenta))?;
|
writer.stdout.queue(SetForegroundColor(Color::Magenta))?;
|
||||||
writer.write_str(&self.message)?;
|
writer.write_str(&self.message)?;
|
||||||
stdout.queue(ResetColor)?;
|
stdout.queue(ResetColor)?;
|
||||||
next_ln(stdout)?;
|
next_ln(stdout)?;
|
||||||
}
|
|
||||||
|
|
||||||
next_ln(stdout)?;
|
if self.narrow_term {
|
||||||
|
next_ln(stdout)?;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stdout.queue(EndSynchronizedUpdate)?.flush()
|
stdout.queue(EndSynchronizedUpdate)?.flush()
|
||||||
|
|
Loading…
Reference in a new issue