diff options
| author | Glenn Morris | 2008-03-01 20:31:09 +0000 |
|---|---|---|
| committer | Glenn Morris | 2008-03-01 20:31:09 +0000 |
| commit | 60d3008e839218b3c2de242588a98da2ad532e52 (patch) | |
| tree | 182ca8d6fb60467fd7690efed9967584c74df33b | |
| parent | ce8fc80bbd0790fc7134bc620f8e6690e0080570 (diff) | |
| download | emacs-60d3008e839218b3c2de242588a98da2ad532e52.tar.gz emacs-60d3008e839218b3c2de242588a98da2ad532e52.zip | |
More info on how to replace make-variable-frame-local.
| -rw-r--r-- | etc/NEWS.22 | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/etc/NEWS.22 b/etc/NEWS.22 index c97ec91fb51..5778e56ca26 100644 --- a/etc/NEWS.22 +++ b/etc/NEWS.22 | |||
| @@ -135,7 +135,15 @@ because they clash with commands provided by dirtrack.el. Use | |||
| 135 | * Lisp Changes in Emacs 22.2. | 135 | * Lisp Changes in Emacs 22.2. |
| 136 | 136 | ||
| 137 | ** Frame-local variables are deprecated and are slated for removal. | 137 | ** Frame-local variables are deprecated and are slated for removal. |
| 138 | Use frame parameters instead. | 138 | They can easily be emulated. Rather than calling `make-variable-frame-local' |
| 139 | and accessing the variable value directly, explicitly check for a | ||
| 140 | frame-parameter, and if there is one, use its value in preference to | ||
| 141 | that of the variable. Eg: | ||
| 142 | (let ((fp (assoc 'var (frame-parameters)))) | ||
| 143 | ;; Use frame-parameter, even if nil. | ||
| 144 | (if fp (cdr fp) | ||
| 145 | ;; Else use normal variable value. | ||
| 146 | var)) | ||
| 139 | 147 | ||
| 140 | ** The function invisible-p returns non-nil if the character | 148 | ** The function invisible-p returns non-nil if the character |
| 141 | after a specified position is invisible. | 149 | after a specified position is invisible. |