+2016-07-14 Tom Tromey <tom@tromey.com>
+
+ * tui/tui-winsource.c (tui_show_source_line): Use getcurx.
+ * tui/tui-io.c (tui_puts): Use getcurx.
+ (tui_redisplay_readline): Likewise.
+
2016-07-14 Tom Tromey <tom@tromey.com>
* inflow.c (child_terminal_ours_1): Use ATTRIBUTE_UNUSED.
/* Expand TABs, since ncurses on MS-Windows doesn't. */
if (c == '\t')
{
- int line, col;
+ int col;
- getyx (w, line, col);
+ col = getcurx (w);
do
{
waddch (w, ' ');
{
int prev_col;
int height;
- int col, line;
+ int col;
int c_pos;
int c_line;
int in;
for (in = 0; prompt && prompt[in]; in++)
{
waddch (w, prompt[in]);
- getyx (w, line, col);
+ col = getcurx (w);
if (col <= prev_col)
height++;
prev_col = col;
else if (c == '\t')
{
/* Expand TABs, since ncurses on MS-Windows doesn't. */
- getyx (w, line, col);
+ col = getcurx (w);
do
{
waddch (w, ' ');
}
if (c == '\n')
TUI_CMD_WIN->detail.command_info.start_line = getcury (w);
- getyx (w, line, col);
+ col = getcurx (w);
if (col < prev_col)
height++;
prev_col = col;
tui_show_source_line (struct tui_win_info *win_info, int lineno)
{
struct tui_win_element *line;
- int x, y;
+ int x;
line = win_info->generic.content[lineno - 1];
if (line->which_element.source.is_exec_point)
wattroff (win_info->generic.handle, A_STANDOUT);
/* Clear to end of line but stop before the border. */
- getyx (win_info->generic.handle, y, x);
+ x = getcurx (win_info->generic.handle);
while (x + 1 < win_info->generic.width)
{
waddch (win_info->generic.handle, ' ');
- getyx (win_info->generic.handle, y, x);
+ x = getcurx (win_info->generic.handle);
}
}