From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Keith David Bershatsky Newsgroups: gmane.emacs.bugs Subject: bug#22404: 25.1.50; Forcing `window-scroll-functions` to run. Date: Mon, 15 Feb 2016 19:39:38 -0800 Message-ID: <697944A7-4633-48EA-910A-C280D1F3ACFF@lawlist.com> References: <83ziv6734u.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: multipart/mixed; boundary=Apple-Mail-6-545409187 X-Trace: ger.gmane.org 1455594033 3978 80.91.229.3 (16 Feb 2016 03:40:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 16 Feb 2016 03:40:33 +0000 (UTC) Cc: 22404@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Feb 16 04:40:21 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aVWUm-0006lg-8f for geb-bug-gnu-emacs@m.gmane.org; Tue, 16 Feb 2016 04:40:12 +0100 Original-Received: from localhost ([::1]:38809 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVWUl-0007M8-BK for geb-bug-gnu-emacs@m.gmane.org; Mon, 15 Feb 2016 22:40:11 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52677) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVWUh-0007Ks-Im for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 22:40:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aVWUc-0000tp-IJ for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 22:40:07 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:49863) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVWUc-0000ti-EX for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 22:40:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aVWUc-000619-7Q for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 22:40:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Keith David Bershatsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 16 Feb 2016 03:40:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22404 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22404-submit@debbugs.gnu.org id=B22404.145559399123107 (code B ref 22404); Tue, 16 Feb 2016 03:40:02 +0000 Original-Received: (at 22404) by debbugs.gnu.org; 16 Feb 2016 03:39:51 +0000 Original-Received: from localhost ([127.0.0.1]:40638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aVWUR-00060c-G6 for submit@debbugs.gnu.org; Mon, 15 Feb 2016 22:39:51 -0500 Original-Received: from cobb.liquidweb.com ([50.28.13.150]:50303) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aVWUP-00060Q-68 for 22404@debbugs.gnu.org; Mon, 15 Feb 2016 22:39:49 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com; s=default; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Content-Type:Mime-Version:Subject; bh=tflRAE5y/MalzzTsDSEeTr/Vjx9fiMhd6S7j4L0UzIA=; b=6Adm3pHqB8FgUMB6y0VLQtSSXbRgSYK0gZkPglL++NQimuGWYPIWqosMLaZq6j7T5nN+xJaBGUh8flHAZtf0/+++e9MyhzCZMFpYEzJe4vm+IYbN5bfGEaRLfQ0Jq/6M; Original-Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:54751 helo=server.private) by cobb.liquidweb.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.82) (envelope-from ) id 1aVWUE-00013R-9p; Mon, 15 Feb 2016 22:39:39 -0500 In-Reply-To: <83ziv6734u.fsf@gnu.org> X-Mailer: Apple Mail (2.1084) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - cobb.liquidweb.com X-AntiAbuse: Original Domain - debbugs.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lawlist.com X-Get-Message-Sender-Via: cobb.liquidweb.com: authenticated_id: lawlist/from_h X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:113110 Archived-At: --Apple-Mail-6-545409187 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Here is the updated draft of the `window_scroll_functions_hook.diff`. A = copy of this same patch was attached to 22637 today, but I thought it = should be included here also with the 22404. Keith --Apple-Mail-6-545409187 Content-Disposition: attachment; filename=window_start_end_hook.diff Content-Type: application/octet-stream; name="window_start_end_hook.diff" Content-Transfer-Encoding: quoted-printable diff=20--git=20a/src/keyboard.c=20b/src/keyboard.c=0Aindex=20= 3431cd8..3d8d54f=20100644=0A---=20a/src/keyboard.c=0A+++=20= b/src/keyboard.c=0A@@=20-1233,6=20+1233,15=20@@=20static=20int=20= read_key_sequence=20(Lisp_Object=20*,=20int,=20Lisp_Object,=0A=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20bool,=20bool,=20bool,=20bool);=0A=20static=20void=20= adjust_point_for_property=20(ptrdiff_t,=20bool);=0A=20=0A+static=20void=0A= +set_window_start_end_hook=20(void)=0A+{=0A+=20=20Lisp_Object=20window=20= =3D=20(selected_window);=0A+=20=20struct=20window=20*w=20=3D=20= decode_live_window=20(window);=0A+=20=20w->window_start_end_hook_force=20= =3D=20true;=0A+=20=20w->window_start_end_hook_pending=20=3D=20true;=0A+}=0A= +=0A=20Lisp_Object=0A=20command_loop_1=20(void)=0A=20{=0A@@=20-1258,6=20= +1267,8=20@@=20command_loop_1=20(void)=0A=20=20=20=20=20=20=20if=20= (!NILP=20(Vpost_command_hook)=20&&=20!NILP=20(Vrun_hooks))=0A=20=09= safe_run_hooks=20(Qpost_command_hook);=0A=20=0A+=20=20=20=20=20=20= set_window_start_end_hook=20();=0A+=0A=20=20=20=20=20=20=20/*=20If=20= displaying=20a=20message,=20resize=20the=20echo=20area=20window=20to=20= fit=0A=20=09=20that=20message's=20size=20exactly.=20=20*/=0A=20=20=20=20=20= =20=20if=20(!NILP=20(echo_area_buffer[0]))=0A@@=20-1474,6=20+1485,8=20@@=20= command_loop_1=20(void)=0A=20=0A=20=20=20=20=20=20=20safe_run_hooks=20= (Qpost_command_hook);=0A=20=0A+=20=20=20=20=20=20= set_window_start_end_hook=20();=0A+=0A=20=20=20=20=20=20=20/*=20If=20= displaying=20a=20message,=20resize=20the=20echo=20area=20window=20to=20= fit=0A=20=09=20that=20message's=20size=20exactly.=20=20*/=0A=20=20=20=20=20= =20=20if=20(!NILP=20(echo_area_buffer[0]))=0Adiff=20--git=20a/src/lisp.h=20= b/src/lisp.h=0Aindex=208aa2861..0962306=20100644=0A---=20a/src/lisp.h=0A= +++=20b/src/lisp.h=0A@@=20-3913,6=20+3913,7=20@@=20extern=20void=20= init_eval_once=20(void);=0A=20extern=20Lisp_Object=20safe_call=20= (ptrdiff_t,=20Lisp_Object,=20...);=0A=20extern=20Lisp_Object=20= safe_call1=20(Lisp_Object,=20Lisp_Object);=0A=20extern=20Lisp_Object=20= safe_call2=20(Lisp_Object,=20Lisp_Object,=20Lisp_Object);=0A+extern=20= Lisp_Object=20safe_call7=20(Lisp_Object,=20Lisp_Object,=20Lisp_Object,=20= Lisp_Object,=20Lisp_Object,=20Lisp_Object,=20Lisp_Object,=20= Lisp_Object);=0A=20extern=20void=20init_eval=20(void);=0A=20extern=20= void=20syms_of_eval=20(void);=0A=20extern=20void=20unwind_body=20= (Lisp_Object);=0Adiff=20--git=20a/src/window.h=20b/src/window.h=0Aindex=20= c29207d..3156927=20100644=0A---=20a/src/window.h=0A+++=20b/src/window.h=0A= @@=20-348,6=20+348,12=20@@=20struct=20window=0A=20=20=20=20=20=20=20=20= Vwindow_scroll_functions;=20also=20by=20Frecenter=20with=20argument.=20=20= */=0A=20=20=20=20=20bool_bf=20optional_new_start=20:=201;=0A=20=0A+=20=20= =20=20/*=20True=20means=20force=20a=20call=20to=20= Vwindow_start_end_hook.=20=20*/=0A+=20=20=20=20bool_bf=20= window_start_end_hook_force=20:=201;=0A+=0A+=20=20=20=20/*=20True=20= means=20the=20hook=20has=20not=20yet=20run=20with=20point=20fully=20= visible.=20=20*/=0A+=20=20=20=20bool_bf=20window_start_end_hook_pending=20= :=201;=0A+=0A=20=20=20=20=20/*=20True=20means=20the=20cursor=20is=20= currently=20displayed.=20=20This=20can=20be=0A=20=20=20=20=20=20=20=20= set=20to=20zero=20by=20functions=20overpainting=20the=20cursor=20image.=20= =20*/=0A=20=20=20=20=20bool_bf=20phys_cursor_on_p=20:=201;=0Adiff=20= --git=20a/src/xdisp.c=20b/src/xdisp.c=0Aindex=20fed5879..d3e102d=20= 100644=0A---=20a/src/xdisp.c=0A+++=20b/src/xdisp.c=0A@@=20-2618,6=20= +2618,13=20@@=20safe_call2=20(Lisp_Object=20fn,=20Lisp_Object=20arg1,=20= Lisp_Object=20arg2)=0A=20=20=20return=20safe_call=20(3,=20fn,=20arg1,=20= arg2);=0A=20}=0A=20=0A+/*=20=20This=20is=20for=20the=20= `window_start_end_hook'.=20=20Call=20function=20FN=20with=20seven=20= arguments.=0A+=20=20=20=20Return=20the=20result=20or=20nil=20if=20= something=20went=20wrong.=20=20*/=0A+Lisp_Object=0A+safe_call7=20= (Lisp_Object=20fn,=20Lisp_Object=20arg1,=20Lisp_Object=20arg2,=20= Lisp_Object=20arg3,=20Lisp_Object=20arg4,=20Lisp_Object=20arg5,=20= Lisp_Object=20arg6,=20Lisp_Object=20arg7)=0A+{=0A+=20=20return=20= safe_call=20(8,=20fn,=20arg1,=20arg2,=20arg3,=20arg4,=20arg5,=20arg6,=20= arg7);=0A+}=0A=20=0A=20=0C=0A=20= /***********************************************************************=0A= @@=20-13417,6=20+13424,68=20@@=20do=20{=20if=20(!=20= polling_stopped_here)=20stop_polling=20();=09\=0A=20do=20{=20if=20= (polling_stopped_here)=20start_polling=20();=09\=0A=20=20=20=20=20=20=20=20= polling_stopped_here=20=3D=20false;=20}=20while=20(false)=0A=20=0A= +static=20void=0A+run_window_start_end_hook=20(struct=20text_pos=20= startp,=20struct=20window=20*w,=20Lisp_Object=20window,=20struct=20it=20= it,=20char=20*string)=0A+{=0A+=20=20void=20*itdata=20=3D=20NULL;=0A+=20=20= bool=20fully_p=20=3D=20false;=0A+=20=20EMACS_INT=20posint=20=3D=20PT;=0A= +=20=20int=20x,=20y,=20rtop,=20rbot,=20rowh,=20vpos,=20startp_integer,=20= endp,=20pbol_startp,=20peol_endp;=0A+=20=20startp_integer=20=3D=20= CHARPOS=20(startp);=0A+=20=20struct=20buffer=20*buf;=0A+=20=20buf=20=3D=20= XBUFFER=20(w->contents);=0A+=20=20if=20(!NILP=20(Flocal_variable_p=20= (Qwindow_start_end_hook,=20Fwindow_buffer=20(window)))=0A+=20=20=20=20=20= =20&&=20w->window_start_end_hook_pending)=0A+=20=20=20=20{=0A+=20=20=20=20= =20=20if=20((posint=20>=3D=20CHARPOS=20(startp)=20&&=20posint=20<=3D=20= BUF_ZV=20(buf))=0A+=20=20=20=20=20=20=20=20=20=20&&=20CHARPOS=20(startp)=20= >=3D=20BUF_BEGV=20(buf)=0A+=20=20=20=20=20=20=20=20=20=20&&=20CHARPOS=20= (startp)=20<=3D=20BUF_ZV=20(buf)=0A+=20=20=20=20=20=20=20=20=20=20&&=20= pos_visible_p=20(w,=20posint,=20&x,=20&y,=20&rtop,=20&rbot,=20&rowh,=20= &vpos))=0A+=20=20=20=20=20=20=20=20fully_p=20=3D=20!rtop=20&&=20!rbot;=0A= +=20=20=20=20=20=20if=20(fully_p)=0A+=20=20=20=20=20=20=20=20{=0A+=20=20=20= =20=20=20=20=20=20=20CLIP_TEXT_POS_FROM_MARKER=20(startp,=20w->start);=0A= +=20=20=20=20=20=20=20=20=20=20itdata=20=3D=20bidi_shelve_cache=20();=0A= +=20=20=20=20=20=20=20=20=20=20start_display=20(&it,=20w,=20startp);=0A+=20= =20=20=20=20=20=20=20=20=20move_it_vertically=20(&it,=20= window_box_height=20(w));=0A+=20=20=20=20=20=20=20=20=20=20if=20= (it.current_y=20<=20it.last_visible_y)=0A+=20=20=20=20=20=20=20=20=20=20=20= =20move_it_past_eol=20(&it);=0A+=20=20=20=20=20=20=20=20=20=20endp=20=3D=20= (IT_CHARPOS=20(it));=0A+=20=20=20=20=20=20=20=20=20=20= bidi_unshelve_cache=20(itdata,=20false);=0A+=20=20=20=20=20=20=20=20=20=20= SET_PT=20(startp_integer);=0A+=20=20=20=20=20=20=20=20=20=20pbol_startp=20= =3D=20XINT=20(Fline_beginning_position=20(Qnil));=0A+=20=20=20=20=20=20=20= =20=20=20SET_PT=20(endp);=0A+=20=20=20=20=20=20=20=20=20=20peol_endp=20=3D= =20XINT=20(Fline_end_position=20(Qnil));=0A+=20=20=20=20=20=20=20=20=20=20= SET_PT=20(posint);=0A+#ifdef=20GLYPH_DEBUG=0A+=20=20=20=20=20=20=20=20=20= =20/*=20See=20the=20doc-string=20for=20`pos-visible-in-window-p'.=20=20= */=0A+=20=20=20=20=20=20=20=20=20=20debug_method_add=20(w,=20"%s=20--=20= x:=20%d=20|=20y:=20%d=20|=20startp:=20%d=20|=20endp:=20%d=20|=20= pbol_startp:=20%d=20|=20peol_endp:=20%d",=0A+=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20string,=20= x,=20y,=20startp_integer,=20endp,=20pbol_startp,=20peol_endp);=0A+#endif=0A= +=20=20=20=20=20=20=20=20=20=20/*=20=20Reset=20the=20flag=20_before_=20= calling=20Lisp,=20not=20after,=20so=20that=0A+=20=20=20=20=20=20=20=20=20= =20=20=20=20=20if=20Lisp=20does=20signal=20an=20error,=20the=20flag=20= will=20be=20reset,=20and=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= won't=20cause=20the=20hook=20to=20be=20called=20ad=20nauseam.=20=20*/=0A= +=20=20=20=20=20=20=20=20=20=20w->window_start_end_hook_pending=20=3D=20= false;=0A+=20=20=20=20=20=20=20=20=20=20/*=20=20When=20calling=20Lisp=20= from=20redisplay,=20always=20use=20safe_call,=20to=20be=0A+=20=20=20=20=20= =20=20=20=20=20=20=20=20=20protected=20against=20errors=20signaled=20by=20= that=20Lisp.=20=20*/=0A+=20=20=20=20=20=20=20=20=20=20safe_call7=20= (Qrun_hook_with_args,=20Qwindow_start_end_hook,=0A+=20=20=20=20=20=20=20=20= =20=20=20=20=20=20window,=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= make_number=20(startp_integer),=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20= =20make_number=20(endp),=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= make_number=20(pbol_startp),=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= make_number=20(peol_endp),=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20= fully_p=20?=20Qt=20:=20Qnil);=0A+=20=20=20=20=20=20=20=20}=0A+=20=20=20=20= =20=20=20=20else=0A+=20=20=20=20=20=20=20=20=20=20{=0A+#ifdef=20= GLYPH_DEBUG=0A+=20=20=20=20=20=20=20=20=20=20=20=20/*=20See=20the=20= doc-string=20for=20`pos-visible-in-window-p'.=20=20*/=0A+=20=20=20=20=20=20= =20=20=20=20=20=20debug_method_add=20(w,=20"%s=20--=20x:=20%d=20|=20y:=20= %d=20|=20rtop:=20%d=20|=20rbot=20%d=20|=20rowh:=20%d=20|=20vpos:=20%d",=0A= +=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20string,=20x,=20y,=20rtop,=20rbot,=20rowh,=20= vpos);=0A+#endif=0A+=20=20=20=20=20=20=20=20=20=20}=0A+=20=20=20=20}=0A= +}=0A=20=0A=20/*=20Perhaps=20in=20the=20future=20avoid=20recentering=20= windows=20if=20it=0A=20=20=20=20is=20not=20necessary;=20currently=20that=20= causes=20some=20problems.=20=20*/=0A@@=20-13714,6=20+13783,7=20@@=20= redisplay_internal=20(void)=0A=20=20=20=20=20=20=20&&=20match_p=0A=20=20=20= =20=20=20=20&&=20!w->force_start=0A=20=20=20=20=20=20=20&&=20= !w->optional_new_start=0A+=20=20=20=20=20=20&&=20= !w->window_start_end_hook_force=0A=20=20=20=20=20=20=20/*=20Point=20must=20= be=20on=20the=20line=20that=20we=20have=20info=20recorded=20about.=20=20= */=0A=20=20=20=20=20=20=20&&=20PT=20>=3D=20CHARPOS=20(tlbufpos)=0A=20=20=20= =20=20=20=20&&=20PT=20<=3D=20Z=20-=20CHARPOS=20(tlendpos)=0A@@=20= -15418,6=20+15488,8=20@@=20try_scrolling=20(Lisp_Object=20window,=20bool=20= just_this_one_p,=0A=20=20=20/*=20Run=20window=20scroll=20functions.=20=20= */=0A=20=20=20startp=20=3D=20run_window_scroll_functions=20(window,=20= startp);=0A=20=0A+=20=20run_window_start_end_hook=20(startp,=20w,=20= window,=20it,=20"try_scrolling");=0A+=0A=20=20=20/*=20Display=20the=20= window.=20=20Give=20up=20if=20new=20fonts=20are=20loaded,=20or=20if=20= point=0A=20=20=20=20=20=20doesn't=20appear.=20=20*/=0A=20=20=20if=20= (!try_window=20(window,=20startp,=200))=0A@@=20-16082,6=20+16154,7=20@@=20= redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20= =20=20bool=20last_line_misfit=20=3D=20false;=0A=20=20=20ptrdiff_t=20= beg_unchanged,=20end_unchanged;=0A=20=20=20int=20frame_line_height;=0A+=20= =20bool=20window_start_end_hook_suppress_wsf=20=3D=20false;=0A=20=0A=20=20= =20SET_TEXT_POS=20(lpoint,=20PT,=20PT_BYTE);=0A=20=20=20opoint=20=3D=20= lpoint;=0A@@=20-16272,13=20+16345,16=20@@=20redisplay_window=20= (Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20=0A=20=20=20/*=20= If=20someone=20specified=20a=20new=20starting=20point=20but=20did=20not=20= insist,=0A=20=20=20=20=20=20check=20whether=20it=20can=20be=20used.=20=20= */=0A-=20=20if=20((w->optional_new_start=20||=20window_frozen_p=20(w))=0A= +=20=20if=20((w->optional_new_start=20||=20= w->window_start_end_hook_force=20||=20window_frozen_p=20(w))=0A=20=20=20=20= =20=20=20&&=20CHARPOS=20(startp)=20>=3D=20BEGV=0A=20=20=20=20=20=20=20&&=20= CHARPOS=20(startp)=20<=3D=20ZV)=0A=20=20=20=20=20{=0A+=0A+=20=20=20=20=20= =20if=20(w->window_start_end_hook_force=20&&=20!w->optional_new_start=20= &&=20!window_frozen_p=20(w)=20&&=20!w->force_start)=0A+=20=20=20=20=20=20= =20=20window_start_end_hook_suppress_wsf=20=3D=20true;=0A+=0A=20=20=20=20= =20=20=20ptrdiff_t=20it_charpos;=0A=20=0A-=20=20=20=20=20=20= w->optional_new_start=20=3D=20false;=0A=20=20=20=20=20=20=20= start_display=20(&it,=20w,=20startp);=0A=20=20=20=20=20=20=20move_it_to=20= (&it,=20PT,=200,=20it.last_visible_y,=20-1,=0A=20=09=09=20=20MOVE_TO_POS=20= |=20MOVE_TO_X=20|=20MOVE_TO_Y);=0A@@=20-16299,14=20+16375,28=20@@=20= redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20= =09=20=20=20=20w->force_start=20=3D=20true;=0A=20#ifdef=20GLYPH_DEBUG=0A=20= =09=20=20if=20(w->force_start)=0A-=09=20=20=20=20{=0A-=09=20=20=20=20=20=20= if=20(window_frozen_p=20(w))=0A-=09=09debug_method_add=20(w,=20"set=20= force_start=20from=20frozen=20window=20start");=0A-=09=20=20=20=20=20=20= else=0A-=09=09debug_method_add=20(w,=20"set=20force_start=20from=20= optional_new_start");=0A-=09=20=20=20=20}=0A+=20=20=20=20{=0A+=20=20=20=20= =20=20if=20(window_frozen_p=20(w))=0A+=20=20=20=20=20=20=20=20{=0A+=20=20= =20=20=20=20=20=20debug_method_add=20(w,=20"set=20force_start=20from=20= frozen=20window=20start");=0A+=20=20=20=20=20=20}=0A+=20=20=20=20=20=20= else=20if=20(w->optional_new_start)=0A+=20=20=20=20=20=20=20=20{=0A+=20=20= =20=20=20=20=20=20debug_method_add=20(w,=20"set=20force_start=20from=20= optional_new_start");=0A+=20=20=20=20=20=20}=0A+=20=20=20=20=20=20else=20= if=20(w->window_start_end_hook_force)=0A+=20=20=20=20=20=20=20=20{=0A+=20= =20=20=20=20=20=20=20debug_method_add=20(w,=20"set=20force_start=20from=20= window_start_end_hook_force");=0A+=20=20=20=20=20=20}=0A+=20=20=20=20=20=20= else=0A+=20=20=20=20=20=20=20=20{=0A+=20=20=20=20=20=20=20=20= debug_method_add=20(w,=20"This=20situation=20is=20not=20yet=20= contemplated.");=0A+=20=20=20=20=20=20}=0A+=20=20=20=20}=0A=20#endif=0A=20= =09}=0A+=20=20=20=20=20=20w->optional_new_start=20=3D=20false;=0A+=20=20=20= =20=20=20w->window_start_end_hook_force=20=3D=20false;=0A=20=20=20=20=20= }=0A=20=0A=20=20force_start:=0A@@=20-16334,11=20+16424,18=20@@=20= redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20= =09=20than=20to=20get=20into=20an=20infinite=20loop=20calling=20the=20= hook=20functions=0A=20=09=20and=20having=20them=20get=20more=20errors.=20= =20*/=0A=20=20=20=20=20=20=20if=20(!update_mode_line=0A-=09=20=20||=20!=20= NILP=20(Vwindow_scroll_functions))=0A+=09=20=20||=20!=20NILP=20= (Vwindow_scroll_functions)=0A+=09=20=20||=20!=20NILP=20= (Vwindow_start_end_hook))=0A=20=09{=0A=20=09=20=20update_mode_line=20=3D=20= true;=0A=20=09=20=20w->update_mode_line=20=3D=20true;=0A-=09=20=20startp=20= =3D=20run_window_scroll_functions=20(window,=20startp);=0A+=0A+=20=20/*=20= Run=20window=20scroll=20functions.=20=20*/=0A+=20=20if=20= (!window_start_end_hook_suppress_wsf)=0A+=20=20=20=20startp=20=3D=20= run_window_scroll_functions=20(window,=20startp);=0A+=0A+=20=20= run_window_start_end_hook=20(startp,=20w,=20window,=20it,=20= "redisplay_window=20(force_start)");=0A+=0A=20=09}=0A=20=0A=20=20=20=20=20= =20=20if=20(CHARPOS=20(startp)=20<=20BEGV)=0A@@=20-16606,6=20+16703,7=20= @@=20redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A= =20=09=20=20=20=20=20because=20a=20window=20scroll=20function=20can=20= have=20changed=20the=0A=20=09=20=20=20=20=20buffer.=20=20*/=0A=20=09=20=20= ||=20!NILP=20(Vwindow_scroll_functions)=0A+=09=20=20||=20!NILP=20= (Vwindow_start_end_hook)=0A=20=09=20=20||=20MINI_WINDOW_P=20(w)=0A=20=09=20= =20||=20!(used_current_matrix_p=0A=20=09=20=20=20=20=20=20=20=3D=20= try_window_reusing_current_matrix=20(w)))=0A@@=20-16803,6=20+16901,8=20= @@=20redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A= =20=20=20/*=20Run=20scroll=20hooks.=20=20*/=0A=20=20=20startp=20=3D=20= run_window_scroll_functions=20(window,=20it.current.pos);=0A=20=0A+=20=20= run_window_start_end_hook=20(startp,=20w,=20window,=20it,=20= "redisplay_window=20(recenter)");=0A+=0A=20=20=20/*=20Redisplay=20the=20= window.=20=20*/=0A=20=20=20bool=20use_desired_matrix=20=3D=20false;=0A=20= =20=20if=20(!current_matrix_up_to_date_p=0A@@=20-16811,6=20+16911,7=20@@=20= redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20= =20=20=20=20=20=20/*=20Don't=20use=20try_window_reusing_current_matrix=20= in=20this=20case=0A=20=09=20because=20it=20can=20have=20changed=20the=20= buffer.=20=20*/=0A=20=20=20=20=20=20=20||=20!NILP=20= (Vwindow_scroll_functions)=0A+=20=20=20=20=20=20||=20!NILP=20= (Vwindow_start_end_hook)=0A=20=20=20=20=20=20=20||=20!just_this_one_p=0A=20= =20=20=20=20=20=20||=20MINI_WINDOW_P=20(w)=0A=20=20=20=20=20=20=20||=20= !(used_current_matrix_p=0A@@=20-16931,7=20+17032,17=20@@=20= redisplay_window=20(Lisp_Object=20window,=20bool=20just_this_one_p)=0A=20= =09=20=20clear_glyph_matrix=20(w->desired_matrix);=0A=20=09=20=20if=20(1=20= =3D=3D=20try_window=20(window,=20it.current.pos,=0A=20=09=09=09=20=20=20=20= =20=20=20TRY_WINDOW_CHECK_MARGINS))=0A-=09=20=20=20=20goto=20done;=0A+=20= =20=20=20{=0A+=20=20=20=20=20=20if=20(!NILP=20(Flocal_variable_p=20= (Qwindow_start_end_hook,=20Fwindow_buffer=20(window)))=0A+=20=20=20=20=20= =20=20=20=20=20&&=20w->window_start_end_hook_pending)=0A+=20=20=20=20=20=20= =20=20{=0A+=20=20=20=20=20=20=20=20=20=20run_window_start_end_hook=20= (it.current.pos,=20w,=20window,=20it,=20"redisplay_window=20= (post-recenter)");=0A+=20=20=20=20=20=20=20=20=20=20clear_glyph_matrix=20= (w->desired_matrix);=0A+=20=20=20=20=20=20=20=20=20=20try_window=20= (window,=20it.current.pos,=200);=0A+=20=20=20=20=20=20=20=20}=0A+=20=20=20= =20=20=20goto=20done;=0A+=20=20=20=20}=0A+=0A=20=09}=0A=20=0A=20=20=20=20= =20=20=20/*=20If=20centering=20point=20failed=20to=20make=20the=20whole=20= line=20visible,=0A@@=20-23686,6=20+23797,20=20@@=20decode_mode_spec=20= (struct=20window=20*w,=20register=20int=20c,=20int=20field_width,=0A=20=09= =20=20return=20"@";=0A=20=20=20=20=20=20=20}=0A=20=0A+=20=20=20=20case=20= 'w':=0A+=20=20=20=20=20=20{=0A+=20=20ptrdiff_t=20window_start=20=3D=20= marker_position=20(w->start);=0A+=20=20pint2str=20(decode_mode_spec_buf,=20= width,=20window_start);=0A+=20=20return=20decode_mode_spec_buf;=0A+=20=20= =20=20=20=20}=0A+=0A+=20=20=20=20case=20'W':=0A+=20=20=20=20=20=20{=0A+=20= =20ptrdiff_t=20window_end=20=3D=20BUF_Z=20(b)=20-=20w->window_end_pos;=0A= +=20=20pint2str=20(decode_mode_spec_buf,=20width,=20window_end);=0A+=20=20= return=20decode_mode_spec_buf;=0A+=20=20=20=20=20=20}=0A+=0A=20=20=20=20=20= case=20'z':=0A=20=20=20=20=20=20=20/*=20coding-system=20(not=20including=20= end-of-line=20format)=20*/=0A=20=20=20=20=20case=20'Z':=0A@@=20-31151,6=20= +31276,7=20@@=20They=20are=20still=20logged=20to=20the=20*Messages*=20= buffer.=20=20*/);=0A=20=20=20DEFSYM=20(Qoverriding_terminal_local_map,=20= "overriding-terminal-local-map");=0A=20=20=20DEFSYM=20= (Qoverriding_local_map,=20"overriding-local-map");=0A=20=20=20DEFSYM=20= (Qwindow_scroll_functions,=20"window-scroll-functions");=0A+=20=20DEFSYM=20= (Qwindow_start_end_hook,=20"window-start-end-hook");=0A=20=20=20DEFSYM=20= (Qwindow_text_change_functions,=20"window-text-change-functions");=0A=20=20= =20DEFSYM=20(Qredisplay_end_trigger_functions,=20= "redisplay-end-trigger-functions");=0A=20=20=20DEFSYM=20= (Qinhibit_point_motion_hooks,=20"inhibit-point-motion-hooks");=0A@@=20= -31472,6=20+31598,13=20@@=20is=20scrolled.=20=20It=20is=20not=20designed=20= for=20that,=20and=20such=20use=20probably=20won't=0A=20work.=20=20*/);=0A= =20=20=20Vwindow_scroll_functions=20=3D=20Qnil;=0A=20=0A+=20=20= DEFVAR_LISP=20("window-start-end-hook",=20Vwindow_start_end_hook,=0A+=20=20= =20=20doc:=20/*=20A=20bufer-local=20hook=20used=20to=20obtain=20new=20= `window-start`=20and=20`window-end`=0A+during=20redisplay.=20=20The=20= function=20attached=20to=20this=20hook=20has=20the=20following=20= arguments:=0A+WINDOW,=20WINDOW-START,=20WINDOW-END,=20PBOL-START,=20= PEOL-END,=20FULLY-P.=20=20*/);=0A+=20=20Vwindow_start_end_hook=20=3D=20= Qnil;=0A+=20=20Fmake_variable_buffer_local=20(Qwindow_start_end_hook);=0A= +=0A=20=20=20DEFVAR_LISP=20("window-text-change-functions",=0A=20=09=20=20= =20=20=20=20=20Vwindow_text_change_functions,=0A=20=20=20=20=20doc:=20/*=20= Functions=20to=20call=20in=20redisplay=20when=20text=20in=20the=20window=20= might=20change.=20=20*/);=0A= --Apple-Mail-6-545409187--