diff options
| author | Miles Bader | 2007-05-24 02:14:22 +0000 |
|---|---|---|
| committer | Miles Bader | 2007-05-24 02:14:22 +0000 |
| commit | 24236bd83e64a3cfa96f01af3b2a925dd234612d (patch) | |
| tree | 77873f1d6ae4b869cc4264a9e113977cad7ac592 | |
| parent | f9263a779af1a6436e05c87756747eb13883593b (diff) | |
| parent | 698c8370d994f75b78ca711a3144f18b0a26ca89 (diff) | |
| download | emacs-24236bd83e64a3cfa96f01af3b2a925dd234612d.tar.gz emacs-24236bd83e64a3cfa96f01af3b2a925dd234612d.zip | |
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 762-764)
- Update from CVS
- Merge from emacs--rel--22
* emacs--rel--22 (patch 22-23)
- Update from CVS
Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-15
| -rw-r--r-- | admin/FOR-RELEASE | 24 | ||||
| -rwxr-xr-x | configure | 8 | ||||
| -rw-r--r-- | etc/PROBLEMS | 15 | ||||
| -rw-r--r-- | lisp/ChangeLog | 26 | ||||
| -rw-r--r-- | lisp/files.el | 6 | ||||
| -rw-r--r-- | lisp/image-mode.el | 12 | ||||
| -rw-r--r-- | lisp/image.el | 72 | ||||
| -rw-r--r-- | lisp/mail/mail-extr.el | 12 | ||||
| -rw-r--r-- | lisp/net/rcirc.el | 11 | ||||
| -rw-r--r-- | lisp/paren.el | 9 | ||||
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/image.c | 52 |
12 files changed, 166 insertions, 86 deletions
diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 4d97fed36fd..b3075723e31 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE | |||
| @@ -38,22 +38,26 @@ to the hack introduced on 2005-07-01 to fix some other Cleartype problem. | |||
| 38 | ** henman@it.to-be.co.jp 09 Aug 2006: ispell.el problem on Cygwin. | 38 | ** henman@it.to-be.co.jp 09 Aug 2006: ispell.el problem on Cygwin. |
| 39 | (Did we decide that is unreproducible?) | 39 | (Did we decide that is unreproducible?) |
| 40 | 40 | ||
| 41 | * BUGS | 41 | ** eliz@gnu.org, May 20: EOL conversion of files in .tar archives |
| 42 | |||
| 43 | See the copy of this file on the EMACS_22_BASE branch. | ||
| 44 | 42 | ||
| 45 | ** rcyeske@gmail.com, April 22: Failure to build on OpenBSD macppc. | 43 | * BUGS |
| 46 | OpenBSD compilation works on i386. | ||
| 47 | http://lists.gnu.org/archive/html/emacs-devel/2007-04/msg00932.html | ||
| 48 | 44 | ||
| 49 | ** Spurious redisplay bug not fixed. | 45 | NB the definitive copy of this file for Emacs 22 is on the |
| 50 | http://lists.gnu.org/archive/html/emacs-devel/2007-04/msg00443.html | 46 | EMACS_22_BASE branch. Any entries below are automatically copied from |
| 51 | http://lists.gnu.org/archive/html/emacs-devel/2007-04/msg00732.html | 47 | that branch. Do not make manual changes to this file on the trunk. |
| 52 | 48 | ||
| 53 | ** michael.ewe@arcor.de, Apr 24: 22.0.98 not starting on Solaris 10/I386 | 49 | ** michael.ewe@arcor.de, Apr 24: 22.0.98 not starting on Solaris 10/I386 |
| 54 | http://lists.gnu.org/archive/html/emacs-devel/2007-04/msg01113.html | 50 | http://lists.gnu.org/archive/html/emacs-devel/2007-04/msg01113.html |
| 55 | 51 | ||
| 56 | ** coldwell@redhat.com, May 18: 22.0.99 emacs dumper (?) problem | 52 | * FIXES FOR EMACS 22.2 |
| 53 | |||
| 54 | Here we list small fixes that arrived too late for Emacs 22.1, but | ||
| 55 | that should be installed on the release branch after 22.1 is released. | ||
| 56 | |||
| 57 | ** Changes to six pbm icons in etc/images. | ||
| 58 | Sync change from trunk 2007-05-19. | ||
| 59 | |||
| 60 | ** viper and tramp should not load cl at run time. | ||
| 57 | 61 | ||
| 58 | * DOCUMENTATION | 62 | * DOCUMENTATION |
| 59 | 63 | ||
| @@ -412,10 +412,10 @@ else | |||
| 412 | fi | 412 | fi |
| 413 | 413 | ||
| 414 | test \$exitcode = 0") || { | 414 | test \$exitcode = 0") || { |
| 415 | echo No shell found that supports shell functions. | 415 | echo Please tell bug-autoconf@gnu.org about your system, |
| 416 | echo Please tell autoconf@gnu.org about your system, | 416 | echo including any error possibly output before this message. |
| 417 | echo including any error possibly output before this | 417 | echo This can help us improve future autoconf versions. |
| 418 | echo message | 418 | echo Configuration will now proceed without shell functions. |
| 419 | } | 419 | } |
| 420 | 420 | ||
| 421 | 421 | ||
diff --git a/etc/PROBLEMS b/etc/PROBLEMS index efa2bbd2227..00bddb791c2 100644 --- a/etc/PROBLEMS +++ b/etc/PROBLEMS | |||
| @@ -144,6 +144,21 @@ Reportedly this patch in X fixes the problem. | |||
| 144 | } | 144 | } |
| 145 | return ret; | 145 | return ret; |
| 146 | 146 | ||
| 147 | ** Emacs crashes on startup after a glibc upgrade. | ||
| 148 | |||
| 149 | This is caused by a binary incompatible change to the malloc | ||
| 150 | implementation in glibc 2.5.90-22. As a result, Emacs binaries built | ||
| 151 | using prior versions of glibc crash when run under 2.5.90-22. | ||
| 152 | |||
| 153 | This problem was first seen in pre-release versions of Fedora 7, and | ||
| 154 | may be fixed in the final Fedora 7 release. To stop the crash from | ||
| 155 | happening, first try upgrading to the newest version of glibc; if this | ||
| 156 | does not work, rebuild Emacs with the same version of glibc that you | ||
| 157 | will run it under. For details, see | ||
| 158 | |||
| 159 | https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=239344 | ||
| 160 | |||
| 161 | |||
| 147 | * Crash bugs | 162 | * Crash bugs |
| 148 | 163 | ||
| 149 | ** Emacs crashes in x-popup-dialog. | 164 | ** Emacs crashes in x-popup-dialog. |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b1e55458363..e7d15008676 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,26 @@ | |||
| 1 | 2007-05-22 Katsumi Yamaoka <yamaoka@jpl.org> (tiny change) | ||
| 2 | |||
| 3 | * mail/mail-extr.el (mail-extract-address-components): Recognize | ||
| 4 | non-ASCII characters except for NBSP as words. | ||
| 5 | |||
| 6 | 2007-05-21 Trent Buck <trentbuck@gmail.com> (tiny change) | ||
| 7 | |||
| 8 | * net/rcirc.el (rcirc-fill-column): Allow `window-width'. | ||
| 9 | (rcirc-print): Handle `window-width'. | ||
| 10 | (rcirc-buffer-maximum-lines): Doc fix. | ||
| 11 | |||
| 12 | 2007-05-21 Chong Yidong <cyd@stupidchicken.com> | ||
| 13 | |||
| 14 | * image-mode.el (image-toggle-display): Don't clear image cache. | ||
| 15 | Only use filename in image spec if the file is readable. Call | ||
| 16 | image-refresh. | ||
| 17 | |||
| 18 | * image.el (image-type-from-file-name, image-type): Simplify. | ||
| 19 | (image-type-auto-detected-p): Don't scan auto-mode-alist. | ||
| 20 | |||
| 21 | * files.el (magic-mode-alist): Remove image-type-auto-detected-p. | ||
| 22 | (magic-fallback-mode-alist): Add image-type-auto-detected-p. | ||
| 23 | |||
| 1 | 2007-05-20 Nick Roberts <nickrob@snap.net.nz> | 24 | 2007-05-20 Nick Roberts <nickrob@snap.net.nz> |
| 2 | 25 | ||
| 3 | * t-mouse.el (t-mouse-mode): Reset t-mouse-mode to nil if there | 26 | * t-mouse.el (t-mouse-mode): Reset t-mouse-mode to nil if there |
| @@ -183,6 +206,9 @@ | |||
| 183 | (set-auto-mode): Handle file-start-mode-alist. | 206 | (set-auto-mode): Handle file-start-mode-alist. |
| 184 | A little cleanup of structure. | 207 | A little cleanup of structure. |
| 185 | 208 | ||
| 209 | * dabbrev.el (dabbrev-eliminate-newlines): | ||
| 210 | Renamed from dabbrev--eliminate-newlines. All uses changed. | ||
| 211 | |||
| 186 | 2007-05-10 Micha,Ak(Bl Cadilhac <michael@cadilhac.name> | 212 | 2007-05-10 Micha,Ak(Bl Cadilhac <michael@cadilhac.name> |
| 187 | 213 | ||
| 188 | * man.el (Man-next-section): Don't consider the last line of the page | 214 | * man.el (Man-next-section): Don't consider the last line of the page |
diff --git a/lisp/files.el b/lisp/files.el index f8d7f875f4b..77043fd8aa0 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -2119,8 +2119,7 @@ is assumed to be interpreted by the interpreter matched by the second group | |||
| 2119 | of the regular expression. The mode is then determined as the mode | 2119 | of the regular expression. The mode is then determined as the mode |
| 2120 | associated with that interpreter in `interpreter-mode-alist'.") | 2120 | associated with that interpreter in `interpreter-mode-alist'.") |
| 2121 | 2121 | ||
| 2122 | (defvar magic-mode-alist | 2122 | (defvar magic-mode-alist nil |
| 2123 | `((image-type-auto-detected-p . image-mode)) | ||
| 2124 | "Alist of buffer beginnings vs. corresponding major mode functions. | 2123 | "Alist of buffer beginnings vs. corresponding major mode functions. |
| 2125 | Each element looks like (REGEXP . FUNCTION) or (MATCH-FUNCTION . FUNCTION). | 2124 | Each element looks like (REGEXP . FUNCTION) or (MATCH-FUNCTION . FUNCTION). |
| 2126 | After visiting a file, if REGEXP matches the text at the beginning of the | 2125 | After visiting a file, if REGEXP matches the text at the beginning of the |
| @@ -2133,7 +2132,8 @@ If FUNCTION is nil, then it is not called. (That is a way of saying | |||
| 2133 | (put 'magic-mode-alist 'risky-local-variable t) | 2132 | (put 'magic-mode-alist 'risky-local-variable t) |
| 2134 | 2133 | ||
| 2135 | (defvar magic-fallback-mode-alist | 2134 | (defvar magic-fallback-mode-alist |
| 2136 | `(;; The < comes before the groups (but the first) to reduce backtracking. | 2135 | `((image-type-auto-detected-p . image-mode) |
| 2136 | ;; The < comes before the groups (but the first) to reduce backtracking. | ||
| 2137 | ;; TODO: UTF-16 <?xml may be preceded by a BOM 0xff 0xfe or 0xfe 0xff. | 2137 | ;; TODO: UTF-16 <?xml may be preceded by a BOM 0xff 0xfe or 0xfe 0xff. |
| 2138 | ;; We use [ \t\r\n] instead of `\\s ' to make regex overflow less likely. | 2138 | ;; We use [ \t\r\n] instead of `\\s ' to make regex overflow less likely. |
| 2139 | (,(let* ((incomment-re "\\(?:[^-]\\|-[^-]\\)") | 2139 | (,(let* ((incomment-re "\\(?:[^-]\\|-[^-]\\)") |
diff --git a/lisp/image-mode.el b/lisp/image-mode.el index eb08de1d6bb..5ff35258c54 100644 --- a/lisp/image-mode.el +++ b/lisp/image-mode.el | |||
| @@ -144,16 +144,17 @@ and showing the image as an image." | |||
| 144 | (message "Repeat this command to go back to displaying the image"))) | 144 | (message "Repeat this command to go back to displaying the image"))) |
| 145 | ;; Turn the image data into a real image, but only if the whole file | 145 | ;; Turn the image data into a real image, but only if the whole file |
| 146 | ;; was inserted | 146 | ;; was inserted |
| 147 | (let* ((image | 147 | (let* ((filename (buffer-file-name)) |
| 148 | (if (and (buffer-file-name) | 148 | (image |
| 149 | (not (file-remote-p (buffer-file-name))) | 149 | (if (and filename |
| 150 | (file-readable-p filename) | ||
| 151 | (not (file-remote-p filename)) | ||
| 150 | (not (buffer-modified-p)) | 152 | (not (buffer-modified-p)) |
| 151 | (not (and (boundp 'archive-superior-buffer) | 153 | (not (and (boundp 'archive-superior-buffer) |
| 152 | archive-superior-buffer)) | 154 | archive-superior-buffer)) |
| 153 | (not (and (boundp 'tar-superior-buffer) | 155 | (not (and (boundp 'tar-superior-buffer) |
| 154 | tar-superior-buffer))) | 156 | tar-superior-buffer))) |
| 155 | (progn (clear-image-cache) | 157 | (create-image filename) |
| 156 | (create-image (buffer-file-name))) | ||
| 157 | (create-image | 158 | (create-image |
| 158 | (string-make-unibyte | 159 | (string-make-unibyte |
| 159 | (buffer-substring-no-properties (point-min) (point-max))) | 160 | (buffer-substring-no-properties (point-min) (point-max))) |
| @@ -169,6 +170,7 @@ and showing the image as an image." | |||
| 169 | (inhibit-read-only t) | 170 | (inhibit-read-only t) |
| 170 | (buffer-undo-list t) | 171 | (buffer-undo-list t) |
| 171 | (modified (buffer-modified-p))) | 172 | (modified (buffer-modified-p))) |
| 173 | (image-refresh image) | ||
| 172 | (add-text-properties (point-min) (point-max) props) | 174 | (add-text-properties (point-min) (point-max) props) |
| 173 | (set-buffer-modified-p modified) | 175 | (set-buffer-modified-p modified) |
| 174 | ;; Inhibit the cursor when the buffer contains only an image, | 176 | ;; Inhibit the cursor when the buffer contains only an image, |
diff --git a/lisp/image.el b/lisp/image.el index c9269abce3e..06f006de252 100644 --- a/lisp/image.el +++ b/lisp/image.el | |||
| @@ -292,43 +292,28 @@ be determined." | |||
| 292 | "Determine the type of image file FILE from its name. | 292 | "Determine the type of image file FILE from its name. |
| 293 | Value is a symbol specifying the image type, or nil if type cannot | 293 | Value is a symbol specifying the image type, or nil if type cannot |
| 294 | be determined." | 294 | be determined." |
| 295 | (let ((types image-type-file-name-regexps) | 295 | (assoc-default file image-type-file-name-regexps 'string-match)) |
| 296 | type) | ||
| 297 | (while types | ||
| 298 | (if (string-match (car (car types)) file) | ||
| 299 | (setq type (cdr (car types)) | ||
| 300 | types nil) | ||
| 301 | (setq types (cdr types)))) | ||
| 302 | type)) | ||
| 303 | 296 | ||
| 304 | 297 | ||
| 305 | ;;;###autoload | 298 | ;;;###autoload |
| 306 | (defun image-type (file-or-data &optional type data-p) | 299 | (defun image-type (source &optional type data-p) |
| 307 | "Determine and return image type. | 300 | "Determine and return image type. |
| 308 | FILE-OR-DATA is an image file name or image data. | 301 | SOURCE is an image file name or image data. |
| 309 | Optional TYPE is a symbol describing the image type. If TYPE is omitted | 302 | Optional TYPE is a symbol describing the image type. If TYPE is omitted |
| 310 | or nil, try to determine the image type from its first few bytes | 303 | or nil, try to determine the image type from its first few bytes |
| 311 | of image data. If that doesn't work, and FILE-OR-DATA is a file name, | 304 | of image data. If that doesn't work, and SOURCE is a file name, |
| 312 | use its file extension as image type. | 305 | use its file extension as image type. |
| 313 | Optional DATA-P non-nil means FILE-OR-DATA is a string containing image data." | 306 | Optional DATA-P non-nil means SOURCE is a string containing image data." |
| 314 | (when (and (not data-p) (not (stringp file-or-data))) | 307 | (when (and (not data-p) (not (stringp source))) |
| 315 | (error "Invalid image file name `%s'" file-or-data)) | 308 | (error "Invalid image file name `%s'" source)) |
| 316 | (cond ((null data-p) | ||
| 317 | ;; FILE-OR-DATA is a file name. | ||
| 318 | (unless (or type | ||
| 319 | (setq type (image-type-from-file-header file-or-data))) | ||
| 320 | (let ((extension (file-name-extension file-or-data))) | ||
| 321 | (unless extension | ||
| 322 | (error "Cannot determine image type")) | ||
| 323 | (setq type (intern extension))))) | ||
| 324 | (t | ||
| 325 | ;; FILE-OR-DATA contains image data. | ||
| 326 | (unless type | ||
| 327 | (setq type (image-type-from-data file-or-data))))) | ||
| 328 | (unless type | 309 | (unless type |
| 329 | (error "Cannot determine image type")) | 310 | (setq type (if data-p |
| 330 | (unless (symbolp type) | 311 | (image-type-from-data source) |
| 331 | (error "Invalid image type `%s'" type)) | 312 | (or (image-type-from-file-header source) |
| 313 | (image-type-from-file-name source)))) | ||
| 314 | (or type (error "Cannot determine image type"))) | ||
| 315 | (or (memq type image-types) | ||
| 316 | (error "Invalid image type `%s'" type)) | ||
| 332 | type) | 317 | type) |
| 333 | 318 | ||
| 334 | 319 | ||
| @@ -343,30 +328,15 @@ Image types are symbols like `xbm' or `jpeg'." | |||
| 343 | ;;;###autoload | 328 | ;;;###autoload |
| 344 | (defun image-type-auto-detected-p () | 329 | (defun image-type-auto-detected-p () |
| 345 | "Return t iff the current buffer contains an auto-detectable image. | 330 | "Return t iff the current buffer contains an auto-detectable image. |
| 346 | This function is intended to be used from `magic-mode-alist' (which see). | 331 | This function is intended to be used from `magic-fallback-mode-alist'. |
| 347 | 332 | ||
| 348 | First, compare the beginning of the buffer with `image-type-header-regexps'. | 333 | The buffer is considered to contain an auto-detectable image if |
| 349 | If an appropriate image type is found, check if that image type can be | 334 | its beginning matches an image type in `image-type-header-regexps', |
| 350 | autodetected using the variable `image-type-auto-detectable'. Finally, | 335 | and that image type is present in `image-type-auto-detectable'." |
| 351 | if `buffer-file-name' is non-nil, check if it matches another major mode | ||
| 352 | in `auto-mode-alist' apart from `image-mode'; if there is another match, | ||
| 353 | the autodetection is considered to have failed. Return t if all the above | ||
| 354 | steps succeed." | ||
| 355 | (let* ((type (image-type-from-buffer)) | 336 | (let* ((type (image-type-from-buffer)) |
| 356 | (auto (and type (cdr (assq type image-type-auto-detectable))))) | 337 | (auto (and type (cdr (assq type image-type-auto-detectable))))) |
| 357 | (and auto | 338 | (and type |
| 358 | (or (eq auto t) (image-type-available-p type)) | 339 | (or (eq auto t) (image-type-available-p type))))) |
| 359 | (or (null buffer-file-name) | ||
| 360 | (not (assoc-default | ||
| 361 | buffer-file-name | ||
| 362 | (delq nil (mapcar | ||
| 363 | (lambda (elt) | ||
| 364 | (unless (memq (or (car-safe (cdr elt)) | ||
| 365 | (cdr elt)) | ||
| 366 | '(image-mode image-mode-maybe)) | ||
| 367 | elt)) | ||
| 368 | auto-mode-alist)) | ||
| 369 | 'string-match)))))) | ||
| 370 | 340 | ||
| 371 | 341 | ||
| 372 | ;;;###autoload | 342 | ;;;###autoload |
diff --git a/lisp/mail/mail-extr.el b/lisp/mail/mail-extr.el index 9e1b94d8b7a..bfa8d290763 100644 --- a/lisp/mail/mail-extr.el +++ b/lisp/mail/mail-extr.el | |||
| @@ -873,7 +873,17 @@ consing a string.)" | |||
| 873 | (mail-extr-nuke-char-at (point)) | 873 | (mail-extr-nuke-char-at (point)) |
| 874 | (forward-char 1)) | 874 | (forward-char 1)) |
| 875 | (t | 875 | (t |
| 876 | (forward-word 1))) | 876 | ;; Do `(forward-word 1)', recognizing non-ASCII characters |
| 877 | ;; except Latin-1 nbsp as words. | ||
| 878 | (while (progn | ||
| 879 | (skip-chars-forward "^\000-\177 ") | ||
| 880 | (and (not (eobp)) | ||
| 881 | (eq ?w (char-syntax (char-after))) | ||
| 882 | (progn | ||
| 883 | (forward-word 1) | ||
| 884 | (and (not (eobp)) | ||
| 885 | (> (char-after) ?\177) | ||
| 886 | (not (eq (char-after) ? ))))))))) | ||
| 877 | (or (eq char ?\() | 887 | (or (eq char ?\() |
| 878 | ;; At the end of first address of a multiple address header. | 888 | ;; At the end of first address of a multiple address header. |
| 879 | (and (eq char ?,) | 889 | (and (eq char ?,) |
diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index 311c052fa30..60d81aedb7a 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el | |||
| @@ -95,9 +95,11 @@ Each element looks like (SERVER-REGEXP . CHANNEL-LIST)." | |||
| 95 | 95 | ||
| 96 | (defcustom rcirc-fill-column nil | 96 | (defcustom rcirc-fill-column nil |
| 97 | "*Column beyond which automatic line-wrapping should happen. | 97 | "*Column beyond which automatic line-wrapping should happen. |
| 98 | If nil, use value of `fill-column'. If 'frame-width, use the | 98 | If nil, use value of `fill-column'. |
| 99 | maximum frame width." | 99 | If `window-width', use the window's width as maximum. |
| 100 | If `frame-width', use the frame's width as maximum." | ||
| 100 | :type '(choice (const :tag "Value of `fill-column'") | 101 | :type '(choice (const :tag "Value of `fill-column'") |
| 102 | (const :tag "Full window width" window-width) | ||
| 101 | (const :tag "Full frame width" frame-width) | 103 | (const :tag "Full frame width" frame-width) |
| 102 | (integer :tag "Number of columns")) | 104 | (integer :tag "Number of columns")) |
| 103 | :group 'rcirc) | 105 | :group 'rcirc) |
| @@ -143,8 +145,7 @@ number. If zero or nil, no truncating is done." | |||
| 143 | :group 'rcirc) | 145 | :group 'rcirc) |
| 144 | 146 | ||
| 145 | (defcustom rcirc-scroll-show-maximum-output t | 147 | (defcustom rcirc-scroll-show-maximum-output t |
| 146 | "*If non-nil, scroll buffer to keep the point at the bottom of | 148 | "*If non-nil, scroll buffer to keep the point at the bottom of the window." |
| 147 | the window." | ||
| 148 | :type 'boolean | 149 | :type 'boolean |
| 149 | :group 'rcirc) | 150 | :group 'rcirc) |
| 150 | 151 | ||
| @@ -1245,6 +1246,8 @@ record activity." | |||
| 1245 | (make-string (- text-start fill-start) ?\s))) | 1246 | (make-string (- text-start fill-start) ?\s))) |
| 1246 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) | 1247 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) |
| 1247 | (1- (frame-width))) | 1248 | (1- (frame-width))) |
| 1249 | ((eq rcirc-fill-column 'window-width) | ||
| 1250 | (1- (window-width))) | ||
| 1248 | (rcirc-fill-column | 1251 | (rcirc-fill-column |
| 1249 | rcirc-fill-column) | 1252 | rcirc-fill-column) |
| 1250 | (t fill-column)))) | 1253 | (t fill-column)))) |
diff --git a/lisp/paren.el b/lisp/paren.el index 38ac150b402..95f718d5683 100644 --- a/lisp/paren.el +++ b/lisp/paren.el | |||
| @@ -143,7 +143,6 @@ in `show-paren-style' after `show-paren-delay' seconds of Emacs idle time." | |||
| 143 | (let ((oldpos (point)) | 143 | (let ((oldpos (point)) |
| 144 | (dir (cond ((eq (syntax-class (syntax-after (1- (point)))) 5) -1) | 144 | (dir (cond ((eq (syntax-class (syntax-after (1- (point)))) 5) -1) |
| 145 | ((eq (syntax-class (syntax-after (point))) 4) 1))) | 145 | ((eq (syntax-class (syntax-after (point))) 4) 1))) |
| 146 | (window-start (window-start)) | ||
| 147 | pos mismatch face) | 146 | pos mismatch face) |
| 148 | ;; | 147 | ;; |
| 149 | ;; Find the other end of the sexp. | 148 | ;; Find the other end of the sexp. |
| @@ -248,13 +247,7 @@ in `show-paren-style' after `show-paren-delay' seconds of Emacs idle time." | |||
| 248 | ;; | 247 | ;; |
| 249 | ;; Always set the overlay face, since it varies. | 248 | ;; Always set the overlay face, since it varies. |
| 250 | (overlay-put show-paren-overlay 'priority show-paren-priority) | 249 | (overlay-put show-paren-overlay 'priority show-paren-priority) |
| 251 | (overlay-put show-paren-overlay 'face face)) | 250 | (overlay-put show-paren-overlay 'face face))) |
| 252 | ;; If there are continued lines, the above operations can | ||
| 253 | ;; force redisplay to recenter the window (since there is no | ||
| 254 | ;; way for it to know that the overlay changes to the buffer | ||
| 255 | ;; are harmless). So reset the window-start. | ||
| 256 | (unless (window-minibuffer-p) | ||
| 257 | (set-window-start (selected-window) window-start))) | ||
| 258 | ;; show-paren-mode is nil in this buffer. | 251 | ;; show-paren-mode is nil in this buffer. |
| 259 | (and show-paren-overlay | 252 | (and show-paren-overlay |
| 260 | (delete-overlay show-paren-overlay)) | 253 | (delete-overlay show-paren-overlay)) |
diff --git a/src/ChangeLog b/src/ChangeLog index 67f6bd282c2..5cadef9490b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2007-05-21 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * image.c (uncache_image): New function. | ||
| 4 | (Fimage_refresh): New function. | ||
| 5 | |||
| 1 | 2007-05-20 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | 6 | 2007-05-20 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> |
| 2 | 7 | ||
| 3 | * Makefile.in: Move GPM check outside HAVE_X_WINDOWS. | 8 | * Makefile.in: Move GPM check outside HAVE_X_WINDOWS. |
diff --git a/src/image.c b/src/image.c index 5243778526e..dbe200195d0 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -1631,6 +1631,27 @@ make_image_cache () | |||
| 1631 | } | 1631 | } |
| 1632 | 1632 | ||
| 1633 | 1633 | ||
| 1634 | /* Search frame F for an images with spec SPEC, and free it. */ | ||
| 1635 | |||
| 1636 | static void | ||
| 1637 | uncache_image (f, spec) | ||
| 1638 | struct frame *f; | ||
| 1639 | Lisp_Object spec; | ||
| 1640 | { | ||
| 1641 | struct image_cache *c = FRAME_X_IMAGE_CACHE (f); | ||
| 1642 | struct image *img = IMAGE_FROM_ID (f, lookup_image (f, spec)); | ||
| 1643 | unsigned hash = sxhash (spec, 0); | ||
| 1644 | int i = hash % IMAGE_CACHE_BUCKETS_SIZE; | ||
| 1645 | |||
| 1646 | for (img = c->buckets[i]; img; img = img->next) | ||
| 1647 | if (img->hash == hash && !NILP (Fequal (img->spec, spec))) | ||
| 1648 | { | ||
| 1649 | free_image (f, img); | ||
| 1650 | break; | ||
| 1651 | } | ||
| 1652 | } | ||
| 1653 | |||
| 1654 | |||
| 1634 | /* Free image cache of frame F. Be aware that X frames share images | 1655 | /* Free image cache of frame F. Be aware that X frames share images |
| 1635 | caches. */ | 1656 | caches. */ |
| 1636 | 1657 | ||
| @@ -1741,6 +1762,36 @@ FRAME t means clear the image caches of all frames. */) | |||
| 1741 | } | 1762 | } |
| 1742 | 1763 | ||
| 1743 | 1764 | ||
| 1765 | DEFUN ("image-refresh", Fimage_refresh, Simage_refresh, | ||
| 1766 | 1, 2, 0, | ||
| 1767 | doc: /* Refresh the image with specification SPEC on frame FRAME. | ||
| 1768 | If SPEC specifies an image file, the displayed image is updated with | ||
| 1769 | the current contents of that file. | ||
| 1770 | FRAME nil or omitted means use the selected frame. | ||
| 1771 | FRAME t means refresh the image on all frames. */) | ||
| 1772 | (spec, frame) | ||
| 1773 | Lisp_Object spec, frame; | ||
| 1774 | { | ||
| 1775 | if (!valid_image_p (spec)) | ||
| 1776 | error ("Invalid image specification"); | ||
| 1777 | |||
| 1778 | if (EQ (frame, Qt)) | ||
| 1779 | { | ||
| 1780 | Lisp_Object tail; | ||
| 1781 | FOR_EACH_FRAME (tail, frame) | ||
| 1782 | { | ||
| 1783 | struct frame *f = XFRAME (frame); | ||
| 1784 | if (FRAME_WINDOW_P (f)) | ||
| 1785 | uncache_image (f, spec); | ||
| 1786 | } | ||
| 1787 | } | ||
| 1788 | else | ||
| 1789 | uncache_image (check_x_frame (frame), spec); | ||
| 1790 | |||
| 1791 | return Qnil; | ||
| 1792 | } | ||
| 1793 | |||
| 1794 | |||
| 1744 | /* Compute masks and transform image IMG on frame F, as specified | 1795 | /* Compute masks and transform image IMG on frame F, as specified |
| 1745 | by the image's specification, */ | 1796 | by the image's specification, */ |
| 1746 | 1797 | ||
| @@ -8662,6 +8713,7 @@ non-numeric, there is no explicit limit on the size of images. */); | |||
| 8662 | 8713 | ||
| 8663 | defsubr (&Sinit_image_library); | 8714 | defsubr (&Sinit_image_library); |
| 8664 | defsubr (&Sclear_image_cache); | 8715 | defsubr (&Sclear_image_cache); |
| 8716 | defsubr (&Simage_refresh); | ||
| 8665 | defsubr (&Simage_size); | 8717 | defsubr (&Simage_size); |
| 8666 | defsubr (&Simage_mask_p); | 8718 | defsubr (&Simage_mask_p); |
| 8667 | defsubr (&Simage_extension_data); | 8719 | defsubr (&Simage_extension_data); |