From: Kim F. Storm Date: Mon, 8 Nov 2004 22:25:30 +0000 (+0000) Subject: (note_mouse_highlight): Clear mouse face if we move out of text area. X-Git-Tag: ttn-vms-21-2-B4~4089 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=4674c583e22f243af1fddb6246e4044f9431c028;p=emacs.git (note_mouse_highlight): Clear mouse face if we move out of text area. --- diff --git a/src/xdisp.c b/src/xdisp.c index b934e706c59..c2d903d347d 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -20970,8 +20970,10 @@ note_mouse_highlight (f, x, y) /* Which window is that in? */ window = window_from_coordinates (f, x, y, &part, 0, 0, 1); - /* If we were displaying active text in another window, clear that. */ - if (! EQ (window, dpyinfo->mouse_face_window)) + /* If we were displaying active text in another window, clear that. + Also clear if we move out of text area in same window. */ + if (! EQ (window, dpyinfo->mouse_face_window) + || (part != ON_TEXT && !NILP (dpyinfo->mouse_face_window))) clear_mouse_face (dpyinfo); /* Not on a window -> return. */