I'm trying to print the current input on my console window, using printw and ncurses, but the first input doesn't give any problem, while the next inputs make the printw overlapping with the other text, as you can see in this image: https://i.stack.imgur.com/v0OsT.png
This is my code:
FCString::Sprintf(sOutput, TEXT("> %s%s"), *sInput, LINE_TERMINATOR);
printw(TCHAR_TO_ANSI(sOutput));
refresh();
The result of Sprintf is "mycommand\n", because LINE_TERMINATOR is \n, so in this case I'm doing printw("> help\n");
This is another screen of what is happening when entering an unknown command and using printw("> Unknown Command: %s", command); https://i.stack.imgur.com/go48X.png