Remove globals 'li' and 'co' in term.c

These globals were used to store the original terminal dimesions from the terminal database (or
in the case of reattaching, supplied by scr-bx) to be applied if the current terminal dimensions
could not be determined.

Instead, we leave the original terminal dimensions in current_term->TI_lines and current_term->TI_cols,
and create current_term->li and current_term->co to store the current terminal dimensions (as eg.
supplied by scr-bx).
This commit is contained in:
Kevin Easton
2017-09-15 17:15:24 +10:00
parent c9b0e654b5
commit 70ac43ce77
8 changed files with 67 additions and 64 deletions

View File

@@ -4209,7 +4209,7 @@ BUILT_IN_FUNCTION(function_channelmode, word)
BUILT_IN_FUNCTION(function_geom, words)
{
/* Erf. CO and LI are ints. (crowman) */
return m_sprintf("%d %d", current_term->TI_cols, current_term->TI_lines);
return m_sprintf("%d %d", current_term->co, current_term->li);
}
BUILT_IN_FUNCTION(function_pass, words)