changeset 9981:f537f1e7264a

(try_window): Don't pass window to Fget_char_property; pass its buffer. (display_text_line): Likewise.
author Roland McGrath <roland@gnu.org>
date Wed, 16 Nov 1994 16:57:31 +0000
parents ff5d8881a3eb
children 65d2d56726ea
files src/xdisp.c
diffstat 1 files changed, 15 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/src/xdisp.c	Wed Nov 16 15:28:37 1994 +0000
+++ b/src/xdisp.c	Wed Nov 16 16:57:31 1994 +0000
@@ -1447,15 +1447,19 @@
       if (val.vpos) tab_offset = 0;
       vpos++;
       if (pos != val.bufpos)
-	last_text_vpos
-	  /* Next line, unless prev line ended in end of buffer with no cr */
-	  = vpos - (val.vpos && (FETCH_CHAR (val.bufpos - 1) != '\n'
+	{
+	  last_text_vpos = vpos;
+	  /* Next line, unless prev line ended in end of buffer with no cr.  */
+	  if (val.vpos && (FETCH_CHAR (val.bufpos - 1) != '\n'
 #ifdef USE_TEXT_PROPERTIES
-				 || ! NILP (Fget_char_property (val.bufpos-1,
-								Qinvisible,
-								window))
+			   || ! NILP (Fget_char_property
+				      (val.bufpos-1,
+				       Qinvisible,
+				       XWINDOW (window)->buffer))
 #endif
-				 ));
+			   ))
+	    --last_text_vpos;
+	}
       pos = val.bufpos;
     }
 
@@ -2252,17 +2256,17 @@
 	     the next property change */
 	  while (pos == next_invisible && pos < end)
 	    {
-	      Lisp_Object position, limit, endpos, prop, ww;
+	      Lisp_Object position, limit, endpos, prop;
 	      XSETFASTINT (position, pos);
-	      XSETWINDOW (ww, w);
-	      prop = Fget_char_property (position, Qinvisible, ww);
+	      prop = Fget_char_property (position, Qinvisible, w->buffer);
 	      /* This is just an estimate to give reasonable
 		 performance; nothing should go wrong if it is too small.  */
 	      limit = Fnext_overlay_change (position);
 	      if (XFASTINT (limit) > pos + 50)
 		XSETFASTINT (limit, pos + 50);
 	      endpos = Fnext_single_property_change (position, Qinvisible,
-						Fcurrent_buffer (), limit);
+						     Fcurrent_buffer (),
+						     limit);
 	      if (INTEGERP (endpos))
 		next_invisible = XINT (endpos);
 	      else