# HG changeset patch # User Gerd Moellmann # Date 988375052 0 # Node ID b8ff923613661f0eb84350a9fa73feceb50021cc # Parent 0b7a984464cf0b7df8429a10f841e55cc5a8b00a (turn_on_face): Fix reverse video handling on terminals that don't support colors. diff -r 0b7a984464cf -r b8ff92361366 src/term.c --- a/src/term.c Thu Apr 26 19:46:26 2001 +0000 +++ b/src/term.c Fri Apr 27 12:37:32 2001 +0000 @@ -1,5 +1,5 @@ /* terminal control module for terminals described by TERMCAP - Copyright (C) 1985, 86, 87, 93, 94, 95, 98 + Copyright (C) 1985, 86, 87, 93, 94, 95, 98, 2000, 2001 Free Software Foundation, Inc. This file is part of GNU Emacs. @@ -2052,8 +2052,18 @@ { /* If we can't display colors, use reverse video if the face specifies that. */ - if (face->tty_reverse_p) - toggle_highlight (); + if (inverse_video) + { + if (fg == FACE_TTY_DEFAULT_FG_COLOR + || bg == FACE_TTY_DEFAULT_BG_COLOR) + toggle_highlight (); + } + else + { + if (fg == FACE_TTY_DEFAULT_BG_COLOR + || bg == FACE_TTY_DEFAULT_FG_COLOR) + toggle_highlight (); + } } }