Merge pull request #1197 from PatrikLundell/console

Made console prompt respect color reset
develop
Lethosor 2017-12-21 12:43:10 -05:00 committed by GitHub
commit c7f3902e0d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

@ -214,7 +214,10 @@ namespace DFHack
{
COORD pos = { (SHORT)x, (SHORT)y };
DWORD count = 0;
WriteConsoleOutputCharacterA(console_out, str, len, pos, &count);
CONSOLE_SCREEN_BUFFER_INFO inf = { 0 };
GetConsoleScreenBufferInfo(console_out, &inf);
SetConsoleCursorPosition(console_out, pos);
WriteConsoleA(console_out, str, len, &count, NULL);
}
void prompt_refresh()