From 66c5eebd416975af2bb1b2e0557dac967cc51f16 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Mon, 12 Mar 2012 00:27:36 +0800 Subject: [PATCH] * src/editfns.c (Fconstrain_to_field): Doc fix. * doc/lispref/text.texi (Fields): Minor copyedit. Fixes: debbugs:9452 --- doc/lispref/ChangeLog | 2 ++ doc/lispref/text.texi | 2 +- src/ChangeLog | 4 ++++ src/editfns.c | 7 ++++--- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 4b4521c432..3584c89d5f 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -6,6 +6,8 @@ * display.texi (Temporary Displays): with-output-to-temp-buffer is now a macro. + * text.texi (Fields): Minor copyedit. + 2012-03-10 Eli Zaretskii * strings.texi (String Basics): diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi index c60150cc06..1ba0cae43b 100644 --- a/doc/lispref/text.texi +++ b/doc/lispref/text.texi @@ -3777,7 +3777,7 @@ closest to @var{new-pos} that is in the same field as @var{old-pos}. If @var{new-pos} is @code{nil}, then @code{constrain-to-field} uses the value of point instead, and moves point to the resulting position -as well as returning it. +in addition to returning that position. If @var{old-pos} is at the boundary of two fields, then the acceptable final positions depend on the argument @var{escape-from-edge}. If diff --git a/src/ChangeLog b/src/ChangeLog index f77134be49..8d925c7bba 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2012-03-11 Chong Yidong + + * editfns.c (Fconstrain_to_field): Doc fix (Bug#9452). + 2012-03-10 Chong Yidong * frame.c (other_visible_frames): Don't assume the selected frame diff --git a/src/editfns.c b/src/editfns.c index bbeb503366..a41565d858 100644 --- a/src/editfns.c +++ b/src/editfns.c @@ -663,10 +663,11 @@ is after LIMIT, then LIMIT will be returned instead. */) DEFUN ("constrain-to-field", Fconstrain_to_field, Sconstrain_to_field, 2, 5, 0, doc: /* Return the position closest to NEW-POS that is in the same field as OLD-POS. - A field is a region of text with the same `field' property. -If NEW-POS is nil, then the current point is used instead, and set to the -constrained position if that is different. + +If NEW-POS is nil, then use the current point instead, and move point +to the resulting constrained position, in addition to returning that +position. If OLD-POS is at the boundary of two fields, then the allowable positions for NEW-POS depends on the value of the optional argument -- 2.20.1