Remove the TUI annotation hack
do_tui_putc has some code to remove annotations from gdb output. This
was added in 2001, see commit a198b876bb
.
However, I think this code is not needed. It seems very unlikely to
enable both annotations and the TUI, and in any case I think this is
something that should not be supported.
So, this patch removes this code.
gdb/ChangeLog
2020-02-22 Tom Tromey <tom@tromey.com>
* tui/tui-io.c (do_tui_putc): Don't omit annotations.
Change-Id: I05728110365a362d37c9821df9c8779316100bb8
This commit is contained in:
parent
935c78c046
commit
fc96d20b2c
2 changed files with 15 additions and 25 deletions
|
@ -1,3 +1,7 @@
|
|||
2020-02-22 Tom Tromey <tom@tromey.com>
|
||||
|
||||
* tui/tui-io.c (do_tui_putc): Don't omit annotations.
|
||||
|
||||
2020-02-22 Tom Tromey <tom@tromey.com>
|
||||
|
||||
* tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
|
||||
|
|
|
@ -138,35 +138,21 @@ static int tui_readline_pipe[2];
|
|||
static void
|
||||
do_tui_putc (WINDOW *w, char c)
|
||||
{
|
||||
static int tui_skip_line = -1;
|
||||
/* Expand TABs, since ncurses on MS-Windows doesn't. */
|
||||
if (c == '\t')
|
||||
{
|
||||
int col;
|
||||
|
||||
/* Catch annotation and discard them. We need two \032 and discard
|
||||
until a \n is seen. */
|
||||
if (c == '\032')
|
||||
{
|
||||
tui_skip_line++;
|
||||
}
|
||||
else if (tui_skip_line != 1)
|
||||
{
|
||||
tui_skip_line = -1;
|
||||
/* Expand TABs, since ncurses on MS-Windows doesn't. */
|
||||
if (c == '\t')
|
||||
col = getcurx (w);
|
||||
do
|
||||
{
|
||||
int col;
|
||||
|
||||
col = getcurx (w);
|
||||
do
|
||||
{
|
||||
waddch (w, ' ');
|
||||
col++;
|
||||
}
|
||||
while ((col % 8) != 0);
|
||||
waddch (w, ' ');
|
||||
col++;
|
||||
}
|
||||
else
|
||||
waddch (w, c);
|
||||
while ((col % 8) != 0);
|
||||
}
|
||||
else if (c == '\n')
|
||||
tui_skip_line = -1;
|
||||
else
|
||||
waddch (w, c);
|
||||
}
|
||||
|
||||
/* Update the cached value of the command window's start line based on
|
||||
|
|
Loading…
Add table
Reference in a new issue