diff options
| author | Eli Zaretskii | 2011-09-22 19:49:57 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2011-09-22 19:49:57 +0300 |
| commit | d4ef2b502ceec1fce8b839ececcb7e781a237880 (patch) | |
| tree | d8310d287292ea5a1db02bdae00e25849e733d63 | |
| parent | 72258fe58401a16ab2ff671601c6d6068eb8b799 (diff) | |
| download | emacs-d4ef2b502ceec1fce8b839ececcb7e781a237880.tar.gz emacs-d4ef2b502ceec1fce8b839ececcb7e781a237880.zip | |
Make "C-x =" show display properties from overlays.
lisp/simple.el (what-cursor-position): Use get-char-property-change
and next-single-char-property-change, to be able to show display
properties that come from overlays as well as text properties.
| -rw-r--r-- | lisp/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/simple.el | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8017e711203..cfa2035db91 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2011-09-22 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * simple.el (what-cursor-position): Use get-char-property-change | ||
| 4 | and next-single-char-property-change, to be able to show display | ||
| 5 | properties that come from overlays as well as text properties. | ||
| 6 | |||
| 1 | 2011-09-22 Chong Yidong <cyd@stupidchicken.com> | 7 | 2011-09-22 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 8 | ||
| 3 | * window.el (pop-to-buffer-same-window): New (reinstated) fun. | 9 | * window.el (pop-to-buffer-same-window): New (reinstated) fun. |
diff --git a/lisp/simple.el b/lisp/simple.el index 4db0aae25ad..3cd46bf284c 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -1054,9 +1054,9 @@ in *Help* buffer. See also the command `describe-char'." | |||
| 1054 | ;; Check if the character is displayed with some `display' | 1054 | ;; Check if the character is displayed with some `display' |
| 1055 | ;; text property. In that case, set under-display to the | 1055 | ;; text property. In that case, set under-display to the |
| 1056 | ;; buffer substring covered by that property. | 1056 | ;; buffer substring covered by that property. |
| 1057 | (setq display-prop (get-text-property pos 'display)) | 1057 | (setq display-prop (get-char-property pos 'display)) |
| 1058 | (if display-prop | 1058 | (if display-prop |
| 1059 | (let ((to (or (next-single-property-change pos 'display) | 1059 | (let ((to (or (next-single-char-property-change pos 'display) |
| 1060 | (point-max)))) | 1060 | (point-max)))) |
| 1061 | (if (< to (+ pos 4)) | 1061 | (if (< to (+ pos 4)) |
| 1062 | (setq under-display "") | 1062 | (setq under-display "") |