diff options
| author | Eli Zaretskii | 2014-09-04 18:21:40 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2014-09-04 18:21:40 +0300 |
| commit | 304661b97fa538d62a2ea984db8ced66f5b852b2 (patch) | |
| tree | 05cb70559ad4b271cb1869485725af76a3c4a3f3 | |
| parent | e97a29cbecc8765aad2bfea5940e215789d4cd7c (diff) | |
| download | emacs-304661b97fa538d62a2ea984db8ced66f5b852b2.tar.gz emacs-304661b97fa538d62a2ea984db8ced66f5b852b2.zip | |
Fix misleading doc string revealed in bug #18385.
lisp/subr.el (posn-actual-col-row): Doc fix.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/subr.el | 13 |
2 files changed, 13 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1e130d05cf6..c716ac8dc0a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2014-09-04 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * subr.el (posn-actual-col-row): Doc fix. (Bug#18385) | ||
| 4 | |||
| 1 | 2014-09-02 Stefan Monnier <monnier@iro.umontreal.ca> | 5 | 2014-09-02 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 6 | ||
| 3 | * emacs-lisp/package.el (package-generate-description-file): | 7 | * emacs-lisp/package.el (package-generate-description-file): |
diff --git a/lisp/subr.el b/lisp/subr.el index 089e3efe79c..12704da149b 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -1149,12 +1149,17 @@ and `event-end' functions." | |||
| 1149 | (/ (cdr pair) (+ (frame-char-height frame) spacing)))))))) | 1149 | (/ (cdr pair) (+ (frame-char-height frame) spacing)))))))) |
| 1150 | 1150 | ||
| 1151 | (defun posn-actual-col-row (position) | 1151 | (defun posn-actual-col-row (position) |
| 1152 | "Return the actual column and row in POSITION, measured in characters. | 1152 | "Return the window row number in POSITION and character number in that row. |
| 1153 | These are the actual row number in the window and character number in that row. | 1153 | |
| 1154 | Return nil if POSITION does not contain the actual position; in that case | 1154 | Return nil if POSITION does not contain the actual position; in that case |
| 1155 | `posn-col-row' can be used to get approximate values. | 1155 | \`posn-col-row' can be used to get approximate values. |
| 1156 | POSITION should be a list of the form returned by the `event-start' | 1156 | POSITION should be a list of the form returned by the `event-start' |
| 1157 | and `event-end' functions." | 1157 | and `event-end' functions. |
| 1158 | |||
| 1159 | This function does not account for the width on display, like the | ||
| 1160 | number of visual columns taken by a TAB or image. If you need | ||
| 1161 | the coordinates of POSITION in character units, you should use | ||
| 1162 | \`posn-col-row', not this function." | ||
| 1158 | (nth 6 position)) | 1163 | (nth 6 position)) |
| 1159 | 1164 | ||
| 1160 | (defsubst posn-timestamp (position) | 1165 | (defsubst posn-timestamp (position) |