How to move the cursor with crossterm

It seems that the structs (MoveUp, MoveDown) are not working.

Because when I use them, for example MoveUp(2); the cursor doesn't move (I do stdout().flush().unwrap()), in the seems that the structs (MoveUp, MoveDown) are not working end It

Because when I use them, for example MoveUp(2); the cursor doesn't move (I do stdout().flush().unwrap()), in the end

Hi there, and welcome here. Sorry your post was stuck in the spam filter a few hours. Also when cross-posting please take a minute to indicate that properly. Which would also help avoid having your post stuck in the spam filter (for being created suspiciously quickly).

I already solved the problem, the problem was that when I used MoveUp(2) I was only creating the struct and not executing it

The solution to the problem is this:

let mut stdout = ...
stdout.queue(MoveUp(5));
// or with their macro
queue!(stdout, MoveUp(5)); 

Thanks: u/InfinitePoints the link to the reddit answer is this:
https://www.reddit.com/r/rust/comments/1ipo1lp/comment/mcvtfne/?utm_source=share&utm_medium=web3x&utm_name=web3xcss&utm_term=1&utm_content=share_button