summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorKaroly Lorentey <lorentey@elte.hu>2006-02-01 02:04:15 +0000
committerKaroly Lorentey <lorentey@elte.hu>2006-02-01 02:04:15 +0000
commiteb2bfdae0a1b6579908f072ab57aec0d80d6c6ec (patch)
tree2abdd13c797be8b59fa9cbd25de93db07ead9ca9 /lisp
parent55187be10d911cb5c0b41b6a64b5e9edb28ae60a (diff)
parent4cdcdcc9ce7ba9f8644432e755a450b1b62b522a (diff)
downloademacs-eb2bfdae0a1b6579908f072ab57aec0d80d6c6ec.tar.gz
Merged from
Patches applied: * emacs@sv.gnu.org/emacs--devo--0--patch-31 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-503
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog21
-rw-r--r--lisp/ediff-mult.el14
-rw-r--r--lisp/emacs-lisp/cl.el3
-rw-r--r--lisp/gnus/ChangeLog50
-rw-r--r--lisp/image-mode.el13
-rw-r--r--lisp/subr.el6
-rw-r--r--lisp/thumbs.el16
-rw-r--r--lisp/window.el32
8 files changed, 92 insertions, 63 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f301c54a609..5a03a2e8502 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,16 @@
+2006-01-30 Chong Yidong <cyd@stupidchicken.com>
+
+ * image-mode.el (image-toggle-display): Use file name if possible,
+ instead of unnecessarily allocating a (possibly huge) lisp string.
+
+2006-01-30 John Paul Wallington <jpw@pobox.com>
+
+ * subr.el (toplevel): Define `cl-assertion-failed' condition here
+ because the `assert' macro signals it at runtime.
+
+ * emacs-lisp/cl.el (toplevel): Remove definition of
+ `cl-assertion-failed' condition.
+
2006-01-30 Nick Roberts <nickrob@snap.net.nz>
* thumbs.el (thumbs-marked-list): Make buffer-local and
@@ -7,6 +20,14 @@
2006-01-30 Juanma Barranquero <lekktu@gmail.com>
+ * ediff-mult.el (ediff-meta-buffer-keymap-setup-hook)
+ (ediff-before-session-group-setup-hooks)
+ (ediff-default-filtering-regexp, ediff-meta-mark-equal-files):
+ Fix typos in docstrings.
+
+ * window.el (bw-dir, bw-eqdir, balance-windows)
+ (split-window-keep-point): Fix typos in docstrings.
+
* textmodes/org.el (org-allow-space-in-links, org-closed-string)
(org-quote-string, org-calendar-to-agenda-key)
(org-agenda-sorting-strategy, org-agenda-use-time-grid)
diff --git a/lisp/ediff-mult.el b/lisp/ediff-mult.el
index 532b491adfa..f4ad4f1e612 100644
--- a/lisp/ediff-mult.el
+++ b/lisp/ediff-mult.el
@@ -176,7 +176,7 @@ directories.")
(defcustom ediff-default-filtering-regexp nil
"The default regular expression used as a filename filter in multifile comparisons.
-Should be a sexp. For instance (car ediff-filtering-regexp-history) or nil."
+Should be a sexp. For instance (car ediff-filtering-regexp-history) or nil."
:type 'sexp
:group 'ediff-mult)
@@ -219,9 +219,9 @@ This can be toggled with `ediff-toggle-filename-truncation'."
(defcustom ediff-before-session-group-setup-hooks nil
"*Hooks to run before Ediff arranges the window for group-level operations.
-It is used by commands such as ediff-directories.
+It is used by commands such as `ediff-directories'.
This hook can be used to save the previous window config, which can be restored
-on ediff-quit, ediff-suspend, or ediff-quit-session-group-hook."
+on `ediff-quit', `ediff-suspend', or `ediff-quit-session-group-hook'."
:type 'hook
:group 'ediff-hook)
(defcustom ediff-after-session-group-setup-hook nil
@@ -242,7 +242,7 @@ ediff-directories, is run."
:type 'hook
:group 'ediff-mult)
(defcustom ediff-meta-buffer-keymap-setup-hook nil
- "*Hooks run just after setting up the ediff-meta-buffer-map.
+ "*Hooks run just after setting up the `ediff-meta-buffer-map'.
This keymap controls key bindings in the meta buffer and is a local variable.
This means that you can set different bindings for different kinds of meta
buffers."
@@ -363,7 +363,7 @@ buffers."
(file-directory-p (ediff-get-session-objC-name session-info)) t)))
;; set up the keymap in the meta buffer
-(defun ediff-setup-meta-map()
+(defun ediff-setup-meta-map ()
(setq ediff-meta-buffer-map (make-sparse-keymap))
(suppress-keymap ediff-meta-buffer-map)
(define-key ediff-meta-buffer-map "q" 'ediff-quit-meta-buffer)
@@ -2332,8 +2332,8 @@ If this is a session registry buffer then just bury it."
"Run through the session list and mark identical files.
This is used only for sessions that involve 2 or 3 files at the same time.
ACTION is an optional argument that can be ?h, ?m, ?=, to mark for hiding, mark
-for operation, or simply indicate which are equal files. If it is nil, then
-last-command-char is used to decide which action to take."
+for operation, or simply indicate which are equal files. If it is nil, then
+`last-command-char' is used to decide which action to take."
(interactive)
(if (null action)
(setq action last-command-char))
diff --git a/lisp/emacs-lisp/cl.el b/lisp/emacs-lisp/cl.el
index 8875366cc9c..b7cf3ad8bcc 100644
--- a/lisp/emacs-lisp/cl.el
+++ b/lisp/emacs-lisp/cl.el
@@ -580,9 +580,6 @@ If ALIST is non-nil, the new pairs are prepended to it."
;;; Miscellaneous.
-(put 'cl-assertion-failed 'error-conditions '(error))
-(put 'cl-assertion-failed 'error-message "Assertion failed")
-
(defvar cl-fake-autoloads nil
"Non-nil means don't make CL functions autoload.")
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index fbbf7281b69..cd98afa3da5 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -122,8 +122,8 @@
2006-01-05 Reiner Steib <Reiner.Steib@gmx.de>
- * gnus-group.el (gnus-useful-groups): Use Gmane for ding. Use
- nntp for bug archive.
+ * gnus-group.el (gnus-useful-groups): Use Gmane for ding.
+ Use nntp for bug archive.
2006-01-05 Katsumi Yamaoka <yamaoka@jpl.org>
@@ -162,7 +162,7 @@
* gnus-msg.el (gnus-copy-article-buffer): Remove MIME buttons
associated with multipart/alternative parts.
-2005-12-19 Mark Plaksin <happy@mcplaksin.org> (tiny change)
+2005-12-19 Mark Plaksin <happy@mcplaksin.org> (tiny change)
* nnrss.el (nnrss-check-group): Put the RSS dc:subject in the
article.
@@ -235,7 +235,7 @@
2005-12-09 ARISAWA Akihiro <ari@mbf.ocn.ne.jp> (tiny change)
- * mm-decode.el (mm-display-external): Add lacked cdr.
+ * mm-decode.el (mm-display-external): Add missing cdr.
2005-12-12 Richard M. Stallman <rms@gnu.org>
@@ -288,7 +288,7 @@
* nnmail.el (nnmail-fancy-expiry-target): Protect against invalid
date header.
-2005-11-16 Boris Samorodov <bsam@ipt.ru> (tiny patch)
+2005-11-16 Boris Samorodov <bsam@ipt.ru> (tiny patch)
* imap.el (imap-kerberos4-open): Ignore SSL stuff.
@@ -329,7 +329,7 @@
error.
(nntp-retrieve-data): Rethrow new error condition to break out of
recursive call to nntp-send-authinfo.
-
+
2005-11-13 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-start.el (gnus-dribble-read-file): Use make-local-variable
@@ -379,8 +379,8 @@
(message-insert-courtesy-copy, message-fill-address)
(message-fill-header, message-shorten-references)
(message-setup-1, message-cancel-news)
- (message-forward-make-body-plain) (message-forward-make-body-mime)
- (message-forward-make-body-mml) (message-encode-message-body)
+ (message-forward-make-body-plain, message-forward-make-body-mime)
+ (message-forward-make-body-mml, message-encode-message-body)
(message-forward-make-body-digest-plain)
(message-forward-make-body-digest-mime)
(message-use-alternative-email-as-from): Insert `hard-newline'
@@ -412,7 +412,7 @@
whitespace removed in revision 7.8. Use concatenated string to
protect trailing whitespace.
-2005-10-27 Jouni K Seppanen <jks@iki.fi> (tiny change)
+2005-10-27 Jouni K Seppanen <jks@iki.fi> (tiny change)
* nnimap.el (nnimap-search-uids-not-since-is-evil): Add variable.
(nnimap-request-expire-articles): Use it to avoid sending 'UID
@@ -511,11 +511,11 @@
* message.el (message-expand-group): Pass the common
prefix substring of completion to `display-completion-list'.
-2005-10-09 Daniel Brockman <daniel@brockman.se>
+2005-10-09 Daniel Brockman <daniel@brockman.se>
* format-spec.el (format-spec): Propagate text properties of % spec.
-2005-01-21 Derek Atkins <warlord@MIT.EDU> (tiny change)
+2005-01-21 Derek Atkins <warlord@MIT.EDU> (tiny change)
* pgg-pgp.el (pgg-pgp-decrypt-region): Use passphrase cache.
@@ -1777,11 +1777,11 @@
* nnimap.el (nnimap-retrieve-headers-from-server): Fix last change.
-2005-03-10 Arne J,Ax(Brgensen <arne@arnested.dk> (tiny change)
+2005-03-10 Arne J,Ax(Brgensen <arne@arnested.dk> (tiny change)
* nnimap.el (nnimap-retrieve-headers-from-server): Fix off-by-one flaw.
-2005-03-08 Bjorn Solberg <bjorn_ding@hekneby.org> (tiny change)
+2005-03-08 Bjorn Solberg <bjorn_ding@hekneby.org> (tiny change)
* nnimap.el (nnimap-retrieve-headers-from-server): Sort NOV
buffer (since IMAP server might return FETCH response out of
@@ -2352,7 +2352,7 @@
* legacy-gnus-agent.el
(gnus-agent-convert-to-compressed-agentview-prompt):
- New function. Used internally to only display 'gnus converting
+ New function. Used internally to only display 'gnus converting
files' message when actually necessary.
* gnus-sum.el: Remove (require 'gnus-agent) as required
@@ -2369,7 +2369,7 @@
(gnus-agent-unfetch-articles): New function.
(gnus-agent-fetch-headers): Use gnus-agent-braid-nov to validate
article numbers even when local .overview file is missing.
- (gnus-agent-read-article-number): New function. Only accepts
+ (gnus-agent-read-article-number): New function. Only accepts
27-bit article numbers.
(gnus-agent-copy-nov-line, gnus-agent-uncached-articles):
Use gnus-agent-read-article-number.
@@ -2465,12 +2465,12 @@
* gnus-agent.el (gnus-agent-read-agentview): Add a missing arg to
error.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-start.el (gnus-convert-old-newsrc): Only write the conversion
message to newsrc-dribble when an actual conversion is performed.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-agent.el (gnus-agent-read-local):
Bind nnheader-file-coding-system to gnus-agent-file-coding-system to
@@ -2479,9 +2479,9 @@
coding-system-for-write, as the with-temp-file macro first prints
to a buffer then saves the buffer.
-2004-10-18 Kevin Greiner <kgreiner@xpediantsolutions.com>
+2004-10-18 Kevin Greiner <kgreiner@xpediantsolutions.com>
- * legacy-gnus-agent.el (): New. Provides converters that are only
+ * legacy-gnus-agent.el (): New. Provides converters that are only
loaded when gnus-convert-old-newsrc needs to call them.
* gnus-agent.el (gnus-agent-read-agentview): Remove support for
@@ -2499,7 +2499,7 @@
should be protected from potentially irreversable changes by the
function.
-2004-10-18 Kevin Greiner <kgreiner@xpediantsolutions.com>
+2004-10-18 Kevin Greiner <kgreiner@xpediantsolutions.com>
* gnus-int.el (gnus-request-accept-article): Inform the agent that
articles are being added to a group.
@@ -2512,7 +2512,7 @@
(gnus-agent-regenerate-group): The REREAD parameter can now be a
list of articles that will be marked as unread.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-range.el (gnus-sorted-range-intersection): Now accepts
single-interval range of the form (min . max). Previously the
@@ -2524,18 +2524,18 @@
* gnus-sum.el (gnus-summary-highlight-line): Articles stored in
the cache, but not the agent, now appear with their usual face.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-sum.el (gnus-adjust-marks): Now correctly handles a list of
marks consisting of a single range {for example, (3 . 5)} rather
than a list of a single range { ((3 . 5)) }.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-sum.el (gnus-adjust-marks): Avoid splicing null INTO the
uncompressed list.
-2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
+2004-10-18 Kevin Greiner <kevin.greiner@compsol.cc>
* gnus-draft.el (gnus-group-send-queue): Pass the group name
"nndraft:queue" along to gnus-draft-send.
@@ -3337,7 +3337,7 @@
* gnus-msg.el (gnus-summary-followup-with-original):
Document yanking of region when active.
-2004-04-13 Kevin Greiner <kgreiner@xpediantsolutions.com>
+2004-04-13 Kevin Greiner <kgreiner@xpediantsolutions.com>
* gnus-agent.el: Merged 7.3 through 7.7 updates into branch.
Revision 7.2 changes excluded to maintain compatibility with all
diff --git a/lisp/image-mode.el b/lisp/image-mode.el
index 67d1bcee995..3c0544edf89 100644
--- a/lisp/image-mode.el
+++ b/lisp/image-mode.el
@@ -137,11 +137,14 @@ and showing the image as an image."
(message "Repeat this command to go back to displaying the image")))
;; Turn the image data into a real image, but only if the whole file
;; was inserted
- (let* ((data
- (string-make-unibyte
- (buffer-substring-no-properties (point-min) (point-max))))
- (image
- (create-image data nil t))
+ (let* ((image
+ (if (and (buffer-file-name)
+ (not (buffer-modified-p)))
+ (create-image (buffer-file-name))
+ (create-image
+ (string-make-unibyte
+ (buffer-substring-no-properties (point-min) (point-max)))
+ nil t)))
(props
`(display ,image
intangible ,image
diff --git a/lisp/subr.el b/lisp/subr.el
index 1433b4c0dfd..b97ed1ba566 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -1831,6 +1831,12 @@ mode.")
This variable is meaningful on MS-DOG and Windows NT.
On those systems, it is automatically local in every buffer.
On other systems, this variable is normally always nil.")
+
+;; The `assert' macro from the cl package signals
+;; `cl-assertion-failed' at runtime so always define it.
+(put 'cl-assertion-failed 'error-conditions '(error))
+(put 'cl-assertion-failed 'error-message "Assertion failed")
+
;;;; Misc. useful functions.
diff --git a/lisp/thumbs.el b/lisp/thumbs.el
index 9999dd72812..bcab502b0f4 100644
--- a/lisp/thumbs.el
+++ b/lisp/thumbs.el
@@ -174,6 +174,8 @@ this value can let another user see some of your images."
(defvar thumbs-marked-list nil
"List of marked files.")
+(make-variable-buffer-local 'thumbs-marked-list)
+(put 'thumbs-marked-list 'permanent-local t)
(defalias 'thumbs-gensym
(if (fboundp 'gensym)
@@ -334,9 +336,9 @@ smaller according to whether INCREMENT is 1 or -1."
((string-match ".*\\.tiff?\\'" img) 'tiff)))
(defun thumbs-file-size (img)
- (let ((i (image-size (find-image `((:type ,(thumbs-image-type img) :file ,img))) t)))
- (concat (number-to-string (round (car i)))
- "x"
+ (let ((i (image-size
+ (find-image `((:type ,(thumbs-image-type img) :file ,img))) t)))
+ (concat (number-to-string (round (car i))) "x"
(number-to-string (round (cdr i))))))
;;;###autoload
@@ -366,7 +368,8 @@ If MARKED is non-nil, the image is marked."
(thumbs-make-thumb img) 'jpeg thumbs-relief marked)
(add-text-properties (1- (point)) (point)
`(thumb-image-file ,img
- help-echo ,(file-name-nondirectory img))))
+ help-echo ,(file-name-nondirectory img)
+ rear-nonsticky help-echo)))
(defun thumbs-do-thumbs-insertion (list)
"Insert all thumbnails into thumbs buffer."
@@ -488,7 +491,7 @@ Open another window."
(let (list)
(goto-char (point-min))
(while (not (eobp))
- (unless (= 0 (mod (point) (1+ thumbs-per-line)))
+ (unless (eolp)
(if (thumbs-current-image)
(push (cons (point-marker)
(thumbs-current-image))
@@ -774,8 +777,7 @@ ACTION and ARG should be a valid convert command."
(define-derived-mode thumbs-mode
fundamental-mode "thumbs"
"Preview images in a thumbnails buffer"
- (setq buffer-read-only t)
- (set (make-local-variable 'thumbs-marked-list) nil))
+ (setq buffer-read-only t))
(defvar thumbs-view-image-mode-map
(let ((map (make-sparse-keymap)))
diff --git a/lisp/window.el b/lisp/window.el
index 6cb553c3799..917edaac57f 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -297,24 +297,24 @@ then the smallest tree containing that window is returned."
;;; Window or object edges
-(defun bw-l(obj)
+(defun bw-l (obj)
"Left edge of OBJ."
(if (windowp obj) (nth 0 (window-edges obj)) (cdr (assq 'l obj))))
-(defun bw-t(obj)
+(defun bw-t (obj)
"Top edge of OBJ."
(if (windowp obj) (nth 1 (window-edges obj)) (cdr (assq 't obj))))
-(defun bw-r(obj)
+(defun bw-r (obj)
"Right edge of OBJ."
(if (windowp obj) (nth 2 (window-edges obj)) (cdr (assq 'r obj))))
-(defun bw-b(obj)
+(defun bw-b (obj)
"Bottom edge of OBJ."
(if (windowp obj) (nth 3 (window-edges obj)) (cdr (assq 'b obj))))
;;; Split directions
-(defun bw-dir(obj)
+(defun bw-dir (obj)
"Return window split tree direction if OBJ.
-If OBJ is a window return 'both. If it is a window split tree
+If OBJ is a window return 'both. If it is a window split tree
then return its direction."
(if (symbolp obj)
obj
@@ -325,10 +325,10 @@ then return its direction."
(error "Can't find dir in %s" obj))
dir))))
-(defun bw-eqdir(obj1 obj2)
+(defun bw-eqdir (obj1 obj2)
"Return t if window split tree directions are equal.
OBJ1 and OBJ2 should be either windows or window split trees in
-our format. The directions returned by `bw-dir' are compared and
+our format. The directions returned by `bw-dir' are compared and
t is returned if they are `eq' or one of them is 'both."
(let ((dir1 (bw-dir obj1))
(dir2 (bw-dir obj2)))
@@ -338,7 +338,7 @@ t is returned if they are `eq' or one of them is 'both."
;;; Building split tree
-(defun bw-refresh-edges(obj)
+(defun bw-refresh-edges (obj)
"Refresh the edge information of OBJ and return OBJ."
(unless (windowp obj)
(let ((childs (cdr (assq 'childs obj)))
@@ -364,12 +364,12 @@ t is returned if they are `eq' or one of them is 'both."
;;; Balance windows
-(defun balance-windows(&optional window-or-frame)
+(defun balance-windows (&optional window-or-frame)
"Make windows the same heights or widths in window split subtrees.
When called non-interactively WINDOW-OR-FRAME may be either a
-window or a frame. It then balances the windows on the implied
-frame. If the parameter is a window only the corresponding window
+window or a frame. It then balances the windows on the implied
+frame. If the parameter is a window only the corresponding window
subtree is balanced."
(interactive)
(let (
@@ -383,7 +383,7 @@ subtree is balanced."
(when wt
(while (not (member last-sizes tried-sizes))
(when last-sizes (setq tried-sizes (cons last-sizes tried-sizes)))
- (setq last-sizes (mapcar (lambda(w)
+ (setq last-sizes (mapcar (lambda (w)
(window-edges w))
windows))
(when (eq 'hor (bw-dir wt))
@@ -392,7 +392,7 @@ subtree is balanced."
(setq h (- (bw-b wt) (bw-t wt))))
(bw-balance-sub wt w h)))))
-(defun bw-adjust-window(window delta horizontal)
+(defun bw-adjust-window (window delta horizontal)
"Wrapper around `adjust-window-trailing-edge' with error checking.
Arguments WINDOW, DELTA and HORIZONTAL are passed on to that function."
(condition-case err
@@ -401,7 +401,7 @@ Arguments WINDOW, DELTA and HORIZONTAL are passed on to that function."
;;(message "adjust: %s" (error-message-string err))
)))
-(defun bw-balance-sub(wt w h)
+(defun bw-balance-sub (wt w h)
(setq wt (bw-refresh-edges wt))
(unless w (setq w (- (bw-r wt) (bw-l wt))))
(unless h (setq h (- (bw-b wt) (bw-t wt))))
@@ -434,7 +434,7 @@ This is convenient on slow terminals, but point can move strangely.
This option applies only to `split-window-vertically' and
functions that call it. `split-window' always keeps the original
-point in both children,"
+point in both children."
:type 'boolean
:group 'windows)