How to print a character with`write!()`, after acquiring it with `Stdin::keys()`
Created by: WarpspeedSCP
I looked at the examples, but they only show the use of println!()
to print the character (the keys example).
How do I extract the character from it so I can use it with write!()
?
It prints well enough with println!()
, but if I pass it to write!()
, it complains about the unimplemented termion::event::Key: std::fmt::Display
trait. I also wish to store the character in a String
, and the method to do either is not really apparent.