1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-03-15 03:11:54 -07:00

(term_init): If "op" isn't available, don't support color

because we can't switch back to the default foreground and
background.
This commit is contained in:
Gerd Moellmann 1999-11-12 14:35:43 +00:00
parent 9b2e6e4cd6
commit e7f90eab7e
2 changed files with 18 additions and 9 deletions

View file

@ -1,5 +1,9 @@
1999-11-12 Gerd Moellmann <gerd@gnu.org>
* term.c (term_init): If "op" isn't available, don't support color
because we can't switch back to the default foreground and
background.
* doc.c (Fdocumentation_property): Remove GCPRO because
Fsubstitute_command_keys gcpro's the string.

View file

@ -2213,18 +2213,23 @@ to do `unset TERMCAP' (C-shell: `unsetenv TERMCAP') as well.",
MultiLeft = tgetstr ("LE", address);
MultiRight = tgetstr ("RI", address);
/* SVr4/ANSI color suppert. */
/* SVr4/ANSI color suppert. If "op" isn't available, don't support
color because we can't switch back to the default foreground and
background. */
TS_orig_pair = tgetstr ("op", address);
TS_set_foreground = tgetstr ("AF", address);
TS_set_background = tgetstr ("AB", address);
if (!TS_set_foreground)
if (TS_orig_pair)
{
/* SVr4. */
TS_set_foreground = tgetstr ("Sf", address);
TS_set_background = tgetstr ("Sb", address);
TS_set_foreground = tgetstr ("AF", address);
TS_set_background = tgetstr ("AB", address);
if (!TS_set_foreground)
{
/* SVr4. */
TS_set_foreground = tgetstr ("Sf", address);
TS_set_background = tgetstr ("Sb", address);
}
TN_max_colors = tgetnum ("Co");
TN_max_pairs = tgetnum ("pa");
}
TN_max_colors = tgetnum ("Co");
TN_max_pairs = tgetnum ("pa");
MagicWrap = tgetflag ("xn");
/* Since we make MagicWrap terminals look like AutoWrap, we need to have