# HG changeset patch # User Kenichi Handa # Date 1043375467 0 # Node ID 7e6cf4411cd40ccb77437af6c46b2cc9ea20b95a # Parent c47a7a3493dae5ddaf5fabf532b949d7ba3e2a2f (adjust_point_for_property): New second arg MODIFIED. It it is nonzero, don't pretend that an invisible area doesn't exist. (command_loop_1): Call adjust_point_for_property with proper second arg. diff -r c47a7a3493da -r 7e6cf4411cd4 src/keyboard.c --- a/src/keyboard.c Thu Jan 23 23:34:59 2003 +0000 +++ b/src/keyboard.c Fri Jan 24 02:31:07 2003 +0000 @@ -1335,7 +1335,7 @@ static int read_key_sequence P_ ((Lisp_Object *, int, Lisp_Object, int, int, int)); void safe_run_hooks P_ ((Lisp_Object)); -static void adjust_point_for_property P_ ((int)); +static void adjust_point_for_property P_ ((int, int)); Lisp_Object command_loop_1 () @@ -1587,7 +1587,7 @@ /* Put this before calling adjust_point_for_property so it will only get called once in any case. */ goto directly_done; - adjust_point_for_property (last_point_position); + adjust_point_for_property (last_point_position, 0); already_adjusted = 1; if (PT == last_point_position + 1 && (dp @@ -1621,7 +1621,7 @@ lose = FETCH_CHAR (PT_BYTE); if (! NILP (Vpost_command_hook)) goto directly_done; - adjust_point_for_property (last_point_position); + adjust_point_for_property (last_point_position, 0); already_adjusted = 1; if (PT == last_point_position - 1 && (dp @@ -1791,7 +1791,7 @@ && NILP (Vdisable_point_adjustment) && NILP (Vglobal_disable_point_adjustment) && !already_adjusted) - adjust_point_for_property (last_point_position); + adjust_point_for_property (last_point_position, MODIFF != prev_modiff); /* Install chars successfully executed in kbd macro. */ @@ -1817,8 +1817,9 @@ extern Lisp_Object get_pos_property P_ ((Lisp_Object, Lisp_Object, Lisp_Object)); static void -adjust_point_for_property (last_pt) +adjust_point_for_property (last_pt, modified) int last_pt; + int modified; { int beg, end; Lisp_Object val, overlay, tmp; @@ -1894,8 +1895,9 @@ check_composition = check_display = 1; } xassert (PT == beg || PT == end); - /* Pretend the area doesn't exist. */ - if (!ellipsis && beg < end) + /* Pretend the area doesn't exist if the buffer is not + modified. */ + if (!modified && !ellipsis && beg < end) { if (last_pt == beg && PT == end && end < ZV) (check_composition = check_display = 1, SET_PT (end + 1));