mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 23:32:09 +00:00
fix a char translation bug in the curses console and make the non-curses
console actually translate chars
This commit is contained in:
parent
06da30ac89
commit
9ffe53178c
1 changed files with 10 additions and 2 deletions
|
@ -194,7 +194,7 @@ C_Print (const char *fmt, va_list args)
|
||||||
|
|
||||||
txt = buffer;
|
txt = buffer;
|
||||||
|
|
||||||
while ((ch = *txt++)) {
|
while ((ch = (byte)*txt++)) {
|
||||||
ch = sys_char_map[ch] | attr_table[attr_map[ch]];
|
ch = sys_char_map[ch] | attr_table[attr_map[ch]];
|
||||||
waddch (output, ch);
|
waddch (output, ch);
|
||||||
}
|
}
|
||||||
|
@ -202,7 +202,15 @@ C_Print (const char *fmt, va_list args)
|
||||||
wrefresh (output);
|
wrefresh (output);
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
vfprintf (stdout, fmt, args);
|
{
|
||||||
|
char msg[4096];
|
||||||
|
unsigned char *p;
|
||||||
|
|
||||||
|
vsnprintf (msg, sizeof (msg), fmt, args);
|
||||||
|
for (p = (unsigned char *) msg; *p; p++)
|
||||||
|
putc (sys_char_map[*p], stdout);
|
||||||
|
fflush (stdout);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in a new issue