aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog206
-rw-r--r--lisp/autorevert.el2
-rw-r--r--lisp/button.el1
-rw-r--r--lisp/calc/calc-aent.el7
-rw-r--r--lisp/calc/calc-arith.el132
-rw-r--r--lisp/calc/calc-math.el19
-rw-r--r--lisp/calc/calc-prog.el20
-rw-r--r--lisp/calc/calcalg2.el30
-rw-r--r--lisp/ediff-diff.el84
-rw-r--r--lisp/ediff-init.el10
-rw-r--r--lisp/ediff-mult.el17
-rw-r--r--lisp/ediff.el13
-rw-r--r--lisp/emulation/viper-cmd.el78
-rw-r--r--lisp/emulation/viper-ex.el2
-rw-r--r--lisp/emulation/viper-init.el11
-rw-r--r--lisp/emulation/viper-keym.el4
-rw-r--r--lisp/emulation/viper-macs.el43
-rw-r--r--lisp/emulation/viper-util.el10
-rw-r--r--lisp/emulation/viper.el10
-rw-r--r--lisp/faces.el5
-rw-r--r--lisp/frame.el80
-rw-r--r--lisp/gnus/ChangeLog37
-rw-r--r--lisp/gnus/gnus-art.el14
-rw-r--r--lisp/gnus/gnus-group.el6
-rw-r--r--lisp/gnus/gnus-msg.el3
-rw-r--r--lisp/gnus/gnus-registry.el4
-rw-r--r--lisp/gnus/gnus-sum.el3
-rw-r--r--lisp/gnus/gnus.el15
-rw-r--r--lisp/gnus/imap.el6
-rw-r--r--lisp/gnus/mml.el3
-rw-r--r--lisp/gnus/nnimap.el8
-rw-r--r--lisp/gnus/rfc2047.el66
-rw-r--r--lisp/isearch.el5
-rw-r--r--lisp/log-view.el6
-rw-r--r--lisp/mouse.el37
-rw-r--r--lisp/net/browse-url.el47
-rw-r--r--lisp/net/tramp.el2
-rw-r--r--lisp/pcvs.el5
-rw-r--r--lisp/progmodes/gdb-ui.el26
-rw-r--r--lisp/progmodes/hideif.el5
-rw-r--r--lisp/progmodes/meta-mode.el2
-rw-r--r--lisp/progmodes/scheme.el4
-rw-r--r--lisp/ps-print.el14
-rw-r--r--lisp/replace.el31
-rw-r--r--lisp/ses.el42
-rw-r--r--lisp/simple.el23
-rw-r--r--lisp/subr.el8
-rw-r--r--lisp/term/mac-win.el26
-rw-r--r--lisp/textmodes/ispell.el6
-rw-r--r--lisp/tooltip.el2
-rw-r--r--lisp/wdired.el2
51 files changed, 914 insertions, 328 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index a435c3a6c5..b18ad4d5bc 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,198 @@
+2005-02-22 Kim F. Storm <[email protected]>
+
+ * progmodes/hideif.el (hide-ifdef-use-define-alist): Use
+ completing-read. Suggested by Juan-Leon Lahoz Garcia.
+
+2005-02-22 Simon Josefsson <[email protected]>
+
+ * net/browse-url.el (browse-url-netscape-new-window-is-tab): New
+ variable.
+ (browse-url-netscape): Use it. Suggested by "Johann 'Myrkraverk'
+ Oskarsson" <[email protected]>.
+
+2005-02-22 Kim F. Storm <[email protected]>
+
+ * mouse.el (mouse-on-link-p): If arg POS is a mouse event,
+ check that window of that event is the selected window.
+ (mouse-drag-region-1): Compare mouse event window to selected
+ window before setting point.
+
+ * tooltip.el (tooltip-show-help-function): Pass event to
+ mouse-on-link-p so it can check selected window.
+
+2005-02-22 Kenichi Handa <[email protected]>
+
+ * ps-mule.el (ps-mule-header-string-charsets): Delete it.
+ (ps-mule-show-warning): New function.
+ (ps-mule-begin-job): Use ps-mule-show-warning if unprintable
+ characters are found.
+
+ * ps-print.el (ps-header-footer-string): Return a list of header
+ and footer strings.
+
+2005-02-21 Wolfgang Jenkner <[email protected]> (tiny change)
+
+ * pcvs.el (cvs-retrieve-revision): Fix thinko.
+
+2005-02-21 Stefan Monnier <[email protected]>
+
+ * frame.el (blink-cursor-mode): Use define-minor-mode.
+
+ * term/mac-win.el (function-key-map): Use char-names more consistently.
+ (file-name-coding-system): Only set it for MacOS-9. The other case is
+ already handled in mule-cmds.el (where it also works when mac-win.el
+ is not used).
+
+2005-02-21 Kenichi Handa <[email protected]>
+
+ * international/mule.el (ctext-pre-write-conversion): Always use
+ " *code-converting-work*" buffer for work.
+
+ * textmodes/ispell.el (ispell-dictionary-alist): Fix docstring.
+
+2005-02-20 Thien-Thi Nguyen <[email protected]>
+
+ * progmodes/scheme.el (scheme-font-lock-keywords-2): Handle named-let.
+
+2005-02-20 Jonathan Yavner <[email protected]>
+
+ * ses.el (undo-more): Restore defadvice, but only the part that
+ allows changes outside the restricted area of the buffer.
+
+2005-02-20 Kim F. Storm <[email protected]>
+
+ * simple.el (line-move): Add fourth optional arg try-vscroll which
+ must be set to perform auto-window-vscroll.
+ When moving backwards and doing auto-window-vscroll, automatically
+ vscroll to the last part of lines which are taller than the window.
+ (next-line, previous-line): Set try-vscroll arg on line-move.
+
+2005-02-19 Dan Nicolaescu <[email protected]>
+
+ * replace.el (query-replace, query-replace-regexp)
+ (replace-string, replace-regexp): When operating on region, make
+ the minibuffer prompt say so.
+
+ * isearch.el (isearch-forward): Document isearch-query-replace and
+ isearch-query-replace-regexp keybindings.
+
+2005-02-19 Jay Belanger <[email protected]>
+
+ * calc/calc-aent.el (math-read-token): Add local variable.
+
+ * calc/calc-prog.el (calc-user-define-edit): Add local variable.
+ (calc-edit-top): Move declaration to earlier in file.
+ (calc-edit-macro-repeats): Add local variables.
+
+ * calc/calcalg2.el: Add differentiation rule for calcFunc-coth.
+ Adjust differentiation rules for calcFunc-tan, calcFunc-cot,
+ calcFunc-tanh.
+ Adjust integration rule for calcFunc-tan.
+
+2005-02-19 Michael Kifer <[email protected]>
+
+ * viper-cmd.el (viper-prefix-commands): Make into a defconst.
+ (viper-exec-buffer-search): Use regexp-quote to quote buffer string.
+ (viper-minibuffer-setup-sentinel): Make some variables buffer-local.
+ (viper-skip-separators): Bug fix.
+ (viper-set-searchstyle-toggling-macros): Allow to unset macros in a
+ particular major mode.
+ (viper-del-backward-char-in-replace): Don't put deleted char on the
+ kill ring.
+
+ * viper-ex.el (viper-color-display-p): New function.
+ (viper-has-face-support-p): Use viper-color-display-p.
+
+ * viper-keym.el (viper-gnus-modifier-map): New keymap.
+
+ * viper-macs.el (viper-unrecord-kbd-macro): Bug fix.
+
+ * viper-util.el (viper-glob-unix-files): Fix shell status check.
+ (viper-file-remote-p): Make equivalent to file-remote-p.
+
+ * viper.el (viper-major-mode-modifier-list): Use
+ viper-gnus-modifier-map.
+
+2005-02-19 David Kastrup <[email protected]>
+
+ * subr.el (subregexp-context-p): Fix garbled doc string by adding
+ quoting.
+
+2005-02-19 Jay Belanger <[email protected]>
+
+ * calc/calc-math.el (calc-arctan, calc-tanh, calc-arctanh):
+ Removed extra definitions.
+ (calc-coth): New function.
+ (calcFunc-cot): Fix `let'.
+
+2005-02-19 Eli Zaretskii <[email protected]>
+
+ * faces.el (escape-glyph, minibuffer-prompt): Add commentary for
+ the reasons we use "type pc" in these faces.
+
+ * button.el (button): Ditto.
+
+2005-02-19 Michael Mauger <[email protected]>
+
+ * replace.el (query-replace-read-from): Set the value of
+ query-replace-from-history-variable to handle the case of an empty
+ string entered to accept the suggested default.
+
+ * net/tramp.el (tramp-file-name-for-operation): Use
+ dired-call-process instead of dired-call-process-command.
+
+2005-02-19 Jay Belanger <[email protected]>
+
+ * calc/calc-arith.el (math-trig-inverses, math-div-trig)
+ (math-div-non-trig): New variables.
+ (math-combine-prod-trig, math-div-new-trig, math-div-new-non-trig)
+ (math-div-isolate-trig, math-div-isolate-trig-term): New functions.
+ (math-combine-prod, math-div-symb-fancy): Add simplifications for
+ trig expressions.
+
+2005-02-19 Nick Roberts <[email protected]>
+
+ * progmodes/gdb-ui.el (gdb-var-update-handler)
+ (gdb-speedbar-timer-fn): Ensure speedbar updates with new values
+ for watch expressions,
+ (gdb-var-create-handler): Don't set speedbar-update-flag.
+ (gdb-post-prompt): Simplify test for speedbar.
+
+2005-02-19 Michael Kifer <[email protected]>
+
+ * ediff.el (ediff-set-diff-overlays-in-one-buffer,
+ ediff-set-fine-overlays-in-one-buffer,ediff-goto-word) make sure
+ we use the syntax table of the correct buffer.
+ (ediff-same-file-contents,ediff-same-contents): enhancements thanks to
+ Felix Gatzemeier.
+
+ * ediff-init.el (ediff-hide-face): checks for definedness of functions.
+ (ediff-file-remote-p): make synonymous with file-remote-p.
+ In all deffaces ediff-*-face-*, use min-colors.
+
+ * ediff-mult.el (ediff-meta-mark-equal-files): make use of
+ ediff-recurse-to-subdirectories.
+ (ediff-mark-if-equal): check that the arguments are strings, use
+ ediff-same-contents (after to Felix Gatzemeier).
+
+ * ediff.el (ediff-merge-on-startup): don't set buffer-modified-p to
+ nil.
+
+2005-02-18 Stefan Monnier <[email protected]>
+
+ * log-view.el (log-view-message-re): Fix up Subversion regexp.
+
+2005-02-18 David Kastrup <[email protected]>
+
+ * progmodes/meta-mode.el (meta-mark-active): Fix condition to just
+ use `mark-active' when defined.
+
+2005-02-18 Kenichi Handa <[email protected]>
+
+ * ps-print.el (ps-font-info-database): New entry
+ ZapfChancery-MediumItalic with correct font name. Fix font name
+ of the entry Zapf-Chancery-MediumItalic.
+
2005-02-16 Luc Teirlinck <[email protected]>
* autorevert.el (auto-revert-stop-on-user-input): Further doc fix.
@@ -82,8 +277,8 @@
2005-02-15 Lute Kamstra <[email protected]>
- * emacs-lisp/lisp-mode.el (lisp-mode-variables): Add
- ;;;###autoload to `outline-regexp'. Suggested by Stefan Monnier
+ * emacs-lisp/lisp-mode.el (lisp-mode-variables):
+ Add ;;;###autoload to `outline-regexp'. Suggested by Stefan Monnier
(lisp-outline-level): Improve efficiency. Suggested by David
Kastrup <[email protected]>.
@@ -158,7 +353,7 @@
* simple.el (eval-expression-print-format):
Avoid warning about edebug-active.
- * help.el (help-for-help-internal): Renamed from help-for-help.
+ * help.el (help-for-help-internal): Rename from help-for-help.
(help-for-help): Define with defalias.
* font-core.el (font-lock-default-function): Use with-no-warnings.
@@ -191,7 +386,7 @@
2005-02-09 Nick Roberts <[email protected]>
* progmodes/gdb-ui.el (gdb-location-list): New variable.
- (gdb-cdir): Delete
+ (gdb-cdir): Delete.
(gdb-info-breakpoints-custom, gdb-goto-breakpoint)
(gdb-source-info): Treat case when source file is in another
directory properly.
@@ -202,8 +397,7 @@
* calc/calc-prog.el (calc-write-parse-table-part)
(calc-fix-token-name): Fix a check for language type.
- * calc/calccomp.el (math-compose-expr): Fix a check for language
- type.
+ * calc/calccomp.el (math-compose-expr): Fix a check for language type.
2005-02-07 Andre Spiegel <[email protected]>
diff --git a/lisp/autorevert.el b/lisp/autorevert.el
index 31dd39c201..d4a3d10d16 100644
--- a/lisp/autorevert.el
+++ b/lisp/autorevert.el
@@ -156,7 +156,7 @@ handling each buffer and does not process any further buffers
\(until the next run of the timer) if user input is available.
When nil, Auto-Revert Mode checks files and reverts buffers,
with quitting disabled, without paying attention to user input.
-Thus, Emacs might be non-responsive at times."
+Thus, with this setting, Emacs might be non-responsive at times."
:group 'auto-revert
:type 'boolean)
diff --git a/lisp/button.el b/lisp/button.el
index dcd26846d1..5f9b5094e6 100644
--- a/lisp/button.el
+++ b/lisp/button.el
@@ -50,6 +50,7 @@
;; Globals
+;; Use color for the MS-DOS port because it doesn't support underline.
(defface button '((((type pc) (class color))
(:foreground "lightblue"))
(t :underline t))
diff --git a/lisp/calc/calc-aent.el b/lisp/calc/calc-aent.el
index 9a693a1846..e174d81c41 100644
--- a/lisp/calc/calc-aent.el
+++ b/lisp/calc/calc-aent.el
@@ -784,7 +784,8 @@ in Calc algebraic input.")
math-exp-pos (match-end 0)
math-expr-data (math-restore-dashes
(math-match-substring math-exp-str 1)))
- (let ((code (assoc math-expr-data math-tex-ignore-words)))
+ (let ((code (assoc math-expr-data math-tex-ignore-words))
+ envname)
(cond ((null code))
((null (cdr code))
(math-read-token))
@@ -801,8 +802,8 @@ in Calc algebraic input.")
(string= envname "bmatrix")
(string= envname "smallmatrix")
(string= envname "pmatrix"))
- (if (setq j (string-match (concat "\\\\end{" envname "}")
- math-exp-str math-exp-pos))
+ (if (string-match (concat "\\\\end{" envname "}")
+ math-exp-str math-exp-pos)
(setq math-exp-str
(replace-match "]" t t math-exp-str))
(error "%s" (concat "No closing \\end{" envname "}"))))))
diff --git a/lisp/calc/calc-arith.el b/lisp/calc/calc-arith.el
index 38c10f5cc9..d9acc2ebc5 100644
--- a/lisp/calc/calc-arith.el
+++ b/lisp/calc/calc-arith.el
@@ -1609,6 +1609,50 @@
(math-reject-arg b "*Division by zero"))
a))))
+;; For math-div-symb-fancy
+(defvar math-trig-inverses
+ '((calcFunc-sin . calcFunc-csc)
+ (calcFunc-cos . calcFunc-sec)
+ (calcFunc-tan . calcFunc-cot)
+ (calcFunc-sec . calcFunc-cos)
+ (calcFunc-csc . calcFunc-sin)
+ (calcFunc-cot . calcFunc-tan)
+ (calcFunc-sinh . calcFunc-csch)
+ (calcFunc-cosh . calcFunc-sech)
+ (calcFunc-tanh . calcFunc-coth)
+ (calcFunc-sech . calcFunc-cosh)
+ (calcFunc-csch . calcFunc-sinh)
+ (calcFunc-coth . calcFunc-tanh)))
+
+(defvar math-div-trig)
+(defvar math-div-non-trig)
+
+(defun math-div-new-trig (tr)
+ (if math-div-trig
+ (setq math-div-trig
+ (list '* tr math-div-trig))
+ (setq math-div-trig tr)))
+
+(defun math-div-new-non-trig (ntr)
+ (if math-div-non-trig
+ (setq math-div-non-trig
+ (list '* ntr math-div-non-trig))
+ (setq math-div-non-trig ntr)))
+
+(defun math-div-isolate-trig (expr)
+ (if (eq (car-safe expr) '*)
+ (progn
+ (math-div-isolate-trig-term (nth 1 expr))
+ (math-div-isolate-trig (nth 2 expr)))
+ (math-div-isolate-trig-term expr)))
+
+(defun math-div-isolate-trig-term (term)
+ (let ((fn (assoc (car-safe term) math-trig-inverses)))
+ (if fn
+ (math-div-new-trig
+ (cons (cdr fn) (cdr term)))
+ (math-div-new-non-trig term))))
+
(defun math-div-symb-fancy (a b)
(or (and math-simplify-only
(not (equal a math-simplify-only))
@@ -1667,6 +1711,15 @@
(list 'calcFunc-idn (math-div a (nth 1 b))))
(and (math-known-matrixp a)
(math-div a (nth 1 b)))))
+ (and math-simplifying
+ (let ((math-div-trig nil)
+ (math-div-non-trig nil))
+ (math-div-isolate-trig b)
+ (if math-div-trig
+ (if math-div-non-trig
+ (math-div (math-mul a math-div-trig) math-div-non-trig)
+ (math-mul a math-div-trig))
+ nil)))
(if (and calc-matrix-mode
(or (math-known-matrixp a) (math-known-matrixp b)))
(math-combine-prod a b nil t nil)
@@ -2674,6 +2727,8 @@
invb
(math-looks-negp (nth 2 b)))
(math-mul a (math-pow (nth 1 b) (math-neg (nth 2 b)))))
+ ((and math-simplifying
+ (math-combine-prod-trig a b)))
(t (let ((apow 1) (bpow 1))
(and (consp a)
(cond ((and (eq (car a) '^)
@@ -2771,6 +2826,83 @@
(math-pow a apow)
(inexact-result (list '^ a apow)))))))))))
+(defun math-combine-prod-trig (a b)
+ (cond
+ ((and (eq (car-safe a) 'calcFunc-sin)
+ (eq (car-safe b) 'calcFunc-csc)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-sin)
+ (eq (car-safe b) 'calcFunc-sec)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-tan (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-sin)
+ (eq (car-safe b) 'calcFunc-cot)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-cos (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-cos)
+ (eq (car-safe b) 'calcFunc-sec)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-cos)
+ (eq (car-safe b) 'calcFunc-csc)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-cot (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-cos)
+ (eq (car-safe b) 'calcFunc-tan)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-sin (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-tan)
+ (eq (car-safe b) 'calcFunc-cot)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-tan)
+ (eq (car-safe b) 'calcFunc-csc)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-sec (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-sec)
+ (eq (car-safe b) 'calcFunc-cot)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-csc (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-sinh)
+ (eq (car-safe b) 'calcFunc-csch)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-sinh)
+ (eq (car-safe b) 'calcFunc-sech)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-tanh (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-sinh)
+ (eq (car-safe b) 'calcFunc-coth)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-cosh (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-cosh)
+ (eq (car-safe b) 'calcFunc-sech)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-cosh)
+ (eq (car-safe b) 'calcFunc-csch)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-coth (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-cosh)
+ (eq (car-safe b) 'calcFunc-tanh)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-sinh (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-tanh)
+ (eq (car-safe b) 'calcFunc-coth)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ 1)
+ ((and (eq (car-safe a) 'calcFunc-tanh)
+ (eq (car-safe b) 'calcFunc-csch)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-sech (cdr a)))
+ ((and (eq (car-safe a) 'calcFunc-sech)
+ (eq (car-safe b) 'calcFunc-coth)
+ (= 0 (math-simplify (math-sub (cdr a) (cdr b)))))
+ (cons 'calcFunc-csch (cdr a)))
+ (t
+ nil)))
+
(defun math-mul-or-div (a b ainv binv)
(if (or (Math-vectorp a) (Math-vectorp b))
(math-normalize
diff --git a/lisp/calc/calc-math.el b/lisp/calc/calc-math.el
index d2c66c34d4..ffb7644cdf 100644
--- a/lisp/calc/calc-math.el
+++ b/lisp/calc/calc-math.el
@@ -236,21 +236,10 @@
(calc-unary-op "coth" 'calcFunc-coth arg)
(calc-unary-op "cot" 'calcFunc-cot arg))))
-(defun calc-arctan (arg)
- (interactive "P")
- (calc-invert-func)
- (calc-tan arg))
-
-(defun calc-tanh (arg)
+(defun calc-coth (arg)
(interactive "P")
(calc-hyperbolic-func)
- (calc-tan arg))
-
-(defun calc-arctanh (arg)
- (interactive "P")
- (calc-invert-func)
- (calc-hyperbolic-func)
- (calc-tan arg))
+ (calc-cot arg))
(defun calc-arctan2 ()
(interactive)
@@ -991,11 +980,11 @@
(or (math-with-extra-prec 2
(let* ((xx (math-to-radians (math-float x)))
(na (math-floor (math-div (nth 2 xx) (math-pi))))
- (nb (math-floor (math-div (nth 3 xx) (math-pi))))
+ (nb (math-floor (math-div (nth 3 xx) (math-pi)))))
(and (equal na nb)
(math-sort-intv (nth 1 x)
(math-cot-raw (nth 2 xx))
- (math-cot-raw (nth 3 xx)))))))
+ (math-cot-raw (nth 3 xx))))))
'(intv 3 (neg (var inf var-inf)) (var inf var-inf))))
((equal x '(var nan var-nan))
x)
diff --git a/lisp/calc/calc-prog.el b/lisp/calc/calc-prog.el
index 640fa5b665..05ec668cce 100644
--- a/lisp/calc/calc-prog.el
+++ b/lisp/calc/calc-prog.el
@@ -671,7 +671,8 @@
(defun calc-user-define-edit ()
(interactive) ; but no calc-wrapper!
(message "Edit definition of command: z-")
- (let* ((key (read-char))
+ (let* (cmdname
+ (key (read-char))
(def (or (assq key (calc-user-key-map))
(assq (upcase key) (calc-user-key-map))
(assq (downcase key) (calc-user-key-map))
@@ -720,17 +721,19 @@
;; Formatting the macro buffer
+(defvar calc-edit-top)
+
(defun calc-edit-macro-repeats ()
(goto-char calc-edit-top)
(while
(re-search-forward "^\\([0-9]+\\)\\*" nil t)
- (setq num (string-to-int (match-string 1)))
- (setq line (buffer-substring (point) (line-end-position)))
- (goto-char (line-beginning-position))
- (kill-line 1)
- (while (> num 0)
- (insert line "\n")
- (setq num (1- num)))))
+ (let ((num (string-to-int (match-string 1)))
+ (line (buffer-substring (point) (line-end-position))))
+ (goto-char (line-beginning-position))
+ (kill-line 1)
+ (while (> num 0)
+ (insert line "\n")
+ (setq num (1- num))))))
(defun calc-edit-macro-adjust-buffer ()
(calc-edit-macro-repeats)
@@ -916,7 +919,6 @@
(delete-char 3)
(insert "<return>")))
-(defvar calc-edit-top)
(defun calc-edit-macro-finish-edit (cmdname key)
"Finish editing a Calc macro.
Redefine the corresponding command."
diff --git a/lisp/calc/calcalg2.el b/lisp/calc/calcalg2.el
index d5a9009c1a..a422ed33e4 100644
--- a/lisp/calc/calcalg2.el
+++ b/lisp/calc/calcalg2.el
@@ -408,9 +408,9 @@
(put 'calcFunc-tan\' 'math-derivative-1
(function (lambda (u) (math-to-radians-2
- (math-div 1 (math-sqr
- (math-normalize
- (list 'calcFunc-cos u))))))))
+ (math-sqr
+ (math-normalize
+ (list 'calcFunc-sec u)))))))
(put 'calcFunc-sec\' 'math-derivative-1
(function (lambda (u) (math-to-radians-2
@@ -432,9 +432,9 @@
(put 'calcFunc-cot\' 'math-derivative-1
(function (lambda (u) (math-neg
(math-to-radians-2
- (math-div 1 (math-sqr
- (math-normalize
- (list 'calcFunc-sin u)))))))))
+ (math-sqr
+ (math-normalize
+ (list 'calcFunc-csc u))))))))
(put 'calcFunc-arcsin\' 'math-derivative-1
(function (lambda (u)
@@ -461,9 +461,9 @@
(function (lambda (u) (math-normalize (list 'calcFunc-sinh u)))))
(put 'calcFunc-tanh\' 'math-derivative-1
- (function (lambda (u) (math-div 1 (math-sqr
- (math-normalize
- (list 'calcFunc-cosh u)))))))
+ (function (lambda (u) (math-sqr
+ (math-normalize
+ (list 'calcFunc-sech u))))))
(put 'calcFunc-sech\' 'math-derivative-1
(function (lambda (u) (math-neg
@@ -477,11 +477,11 @@
(math-normalize (list 'calcFunc-csch u))
(math-normalize (list 'calcFunc-coth u)))))))
-(put 'calcFunc-tanh\' 'math-derivative-1
+(put 'calcFunc-coth\' 'math-derivative-1
(function (lambda (u) (math-neg
- (math-div 1 (math-sqr
- (math-normalize
- (list 'calcFunc-sinh u))))))))
+ (math-sqr
+ (math-normalize
+ (list 'calcFunc-csch u)))))))
(put 'calcFunc-arcsinh\' 'math-derivative-1
(function (lambda (u)
@@ -1664,8 +1664,8 @@
(math-defintegral calcFunc-tan
(and (equal u math-integ-var)
- (math-neg (math-from-radians-2
- (list 'calcFunc-ln (list 'calcFunc-cos u))))))
+ (math-from-radians-2
+ (list 'calcFunc-ln (list 'calcFunc-sec u)))))
(math-defintegral calcFunc-sec
(and (equal u math-integ-var)
diff --git a/lisp/ediff-diff.el b/lisp/ediff-diff.el
index 4ba4ab316f..c41d733aac 100644
--- a/lisp/ediff-diff.el
+++ b/lisp/ediff-diff.el
@@ -534,6 +534,7 @@ one optional arguments, diff-number to refine.")
(defun ediff-set-diff-overlays-in-one-buffer (buf-type diff-list)
(let* ((current-diff -1)
(buff (ediff-get-buffer buf-type))
+ (ctl-buf ediff-control-buffer)
;; ediff-extract-diffs puts the type of diff-list as the first elt
;; of this list. The type is either 'points or 'words
(diff-list-type (car diff-list))
@@ -580,8 +581,9 @@ one optional arguments, diff-number to refine.")
(if (eq diff-list-type 'words)
(progn
(ediff-with-current-buffer buff (goto-char pt-saved))
- (setq begin (ediff-goto-word (1+ begin) buff)
- end (ediff-goto-word end buff 'end))
+ (ediff-with-current-buffer ctl-buf
+ (setq begin (ediff-goto-word (1+ begin) buff)
+ end (ediff-goto-word end buff 'end)))
(if (> end limit) (setq end limit))
(if (> begin end) (setq begin end))
(setq pt-saved (ediff-with-current-buffer buff (point)))))
@@ -864,6 +866,7 @@ delimiter regions"))
(let* ((current-diff -1)
(reg-start (ediff-get-diff-posn buf-type 'beg region-num))
(buff (ediff-get-buffer buf-type))
+ (ctl-buf ediff-control-buffer)
combined-merge-diff-list
diff-overlay-list list-element
begin end overlay)
@@ -892,8 +895,9 @@ delimiter regions"))
() ; skip this diff
;; Put overlays at appropriate places in buffers
;; convert lines to points, if necessary
- (setq begin (ediff-goto-word (1+ begin) buff)
- end (ediff-goto-word end buff 'end))
+ (ediff-with-current-buffer ctl-buf
+ (setq begin (ediff-goto-word (1+ begin) buff)
+ end (ediff-goto-word end buff 'end)))
(setq overlay (ediff-make-bullet-proof-overlay begin end buff))
;; record all overlays for this difference region
(setq diff-overlay-list (nconc diff-overlay-list (list overlay))))
@@ -1326,17 +1330,73 @@ arguments to `skip-chars-forward'."
(while (> n 1)
(funcall fwd-word-fun)
(skip-chars-forward ediff-whitespace)
- (setq n (1- n))))
- (if (and flag (> n 0))
- (funcall fwd-word-fun))
+ (setq n (1- n)))
+ (if (and flag (> n 0))
+ (funcall fwd-word-fun)))
(point))))
(defun ediff-same-file-contents (f1 f2)
- "Return t if F1 and F2 have identical contents."
- (let ((res
- (apply 'call-process ediff-cmp-program nil nil nil
- (append ediff-cmp-options (list f1 f2)))))
- (and (numberp res) (eq res 0))))
+ "Return t if files F1 and F2 have identical contents."
+ (if (and (not (file-directory-p f1))
+ (not (file-directory-p f2)))
+ (let ((res
+ (apply 'call-process ediff-cmp-program nil nil nil
+ (append ediff-cmp-options (list f1 f2)))))
+ (and (numberp res) (eq res 0))))
+ )
+
+
+(defun ediff-same-contents (d1 d2 &optional filter-re)
+ "Returns t iff D1 and D2 have the same content.
+D1 and D2 can either be both directories or both regular files.
+Symlinks and the likes are not handled.
+If FILTER-RE is non-nil, recursive checking in directories
+affects only files whose names match the expression."
+ ;; Normalize empty filter RE to nil.
+ (unless (length filter-re) (setq filter-re nil))
+ ;; Indicate progress
+ (message "Comparing '%s' and '%s' modulo '%s'" d1 d2 filter-re)
+ (cond
+ ;; D1 & D2 directories => recurse
+ ((and (file-directory-p d1)
+ (file-directory-p d2))
+ (if (null ediff-recurse-to-subdirectories)
+ (if (y-or-n-p "Compare subdirectories recursively? ")
+ (setq ediff-recurse-to-subdirectories 'yes)
+ (setq ediff-recurse-to-subdirectories 'no)))
+ (if (eq ediff-recurse-to-subdirectories 'yes)
+ (let* ((all-entries-1 (directory-files d1 t filter-re))
+ (all-entries-2 (directory-files d2 t filter-re))
+ (entries-1 (remove-if (lambda (s)
+ (string-match "^\\.\\.?$"
+ (file-name-nondirectory s)))
+ all-entries-1))
+ (entries-2 (remove-if (lambda (s)
+ (string-match "^\\.\\.?$"
+ (file-name-nondirectory s)))
+ all-entries-2))
+ )
+ ;; First, check only the names (works quickly and ensures a
+ ;; precondition for subsequent code)
+ (if (and (= (length entries-1) (length entries-2))
+ (every (lambda (a b) (equal (file-name-nondirectory a)
+ (file-name-nondirectory b)))
+ entries-1 entries-2))
+ ;; With name equality established, compare the entries
+ ;; through recursion.
+ (every (lambda (a b)
+ (ediff-same-contents a b filter-re))
+ entries-1 entries-2)
+ )
+ ))
+ ) ; end of the directories case
+ ;; D1 & D2 are both files => compare directly
+ ((and (file-regular-p d1)
+ (file-regular-p d2))
+ (ediff-same-file-contents d1 d2))
+ ;; Otherwise => false: unequal contents
+ )
+ )
;;; Local Variables:
diff --git a/lisp/ediff-init.el b/lisp/ediff-init.el
index 80beb4a872..46e94e935f 100644
--- a/lisp/ediff-init.el
+++ b/lisp/ediff-init.el
@@ -895,7 +895,8 @@ to temp files when Ediff needs to find fine differences."
(sit-for 1)))))
(defun ediff-hide-face (face)
- (if (and (ediff-has-face-support-p) (boundp 'add-to-list)
+ (if (and (ediff-has-face-support-p)
+ (boundp 'add-to-list)
(boundp 'facemenu-unlisted-faces))
(add-to-list 'facemenu-unlisted-faces face)))
@@ -1404,7 +1405,7 @@ This property can be toggled interactively."
;;; Misc
;; if nil, this silences some messages
-(defvar ediff-verbose-p t)
+(defconst ediff-verbose-p t)
(defcustom ediff-autostore-merges 'group-jobs-only
"*Save the results of merge jobs automatically.
@@ -1473,11 +1474,8 @@ This default should work without changes."
(ediff-defvar-local ediff-temp-file-C nil "")
-;; If file-remote-p is defined (as in XEmacs, use it. Otherwise, check
-;; if find-file-name-handler is defined for 'file-local-copy
(defun ediff-file-remote-p (file-name)
- (or (and (fboundp 'file-remote-p) (file-remote-p file-name))
- (find-file-name-handler file-name 'file-local-copy)))
+ (file-remote-p file-name))
;; File for which we can get attributes, such as size or date
(defun ediff-listable-file (file-name)
diff --git a/lisp/ediff-mult.el b/lisp/ediff-mult.el
index cf6edc2d12..41a7699cfd 100644
--- a/lisp/ediff-mult.el
+++ b/lisp/ediff-mult.el
@@ -1,6 +1,6 @@
;;; ediff-mult.el --- support for multi-file/multi-buffer processing in Ediff
-;; Copyright (C) 1995, 96, 97, 98, 99, 2000, 01, 02 Free Software Foundation, Inc.
+;; Copyright (C) 1995, 96, 97, 98, 99, 2000, 01, 02, 05 Free Software Foundation, Inc.
;; Author: Michael Kifer <[email protected]>
@@ -167,6 +167,9 @@ directories.")
;; buffer used to collect custom diffs from individual sessions in the group
(ediff-defvar-local ediff-meta-diff-buffer nil "")
+;; t means recurse into subdirs when deciding which files have same contents
+(ediff-defvar-local ediff-recurse-to-subdirectories nil "")
+
;; history var to use for filtering groups of files
(defvar ediff-filtering-regexp-history nil "")
@@ -2349,6 +2352,7 @@ last-command-char is used to decide which action to take."
))
(setq list (cdr list)))
(message "Comparing files ... Done"))
+ (setq ediff-recurse-to-subdirectories nil)
(ediff-update-meta-buffer (current-buffer) 'must-redraw))
;; mark files 1 and 2 as equal, if they are.
@@ -2356,12 +2360,11 @@ last-command-char is used to decide which action to take."
(defun ediff-mark-if-equal (fileinfo1 fileinfo2)
(let ((f1 (car fileinfo1))
(f2 (car fileinfo2)))
- (cond ((file-directory-p f1) nil)
- ((file-directory-p f2) nil)
- ((ediff-same-file-contents f1 f2)
- (ediff-set-file-eqstatus fileinfo1 t)
- (ediff-set-file-eqstatus fileinfo2 t)
- t))
+ (if (and (stringp f1) (stringp f2) (ediff-same-contents f1 f2))
+ (progn
+ (ediff-set-file-eqstatus fileinfo1 t)
+ (ediff-set-file-eqstatus fileinfo2 t)
+ ))
))
diff --git a/lisp/ediff.el b/lisp/ediff.el
index c98974923f..2a2b481ec5 100644
--- a/lisp/ediff.el
+++ b/lisp/ediff.el
@@ -1,13 +1,13 @@
;;; ediff.el --- a comprehensive visual interface to diff & patch
-;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02, 03 Free Software Foundation, Inc.
+;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02, 03, 05 Free Software Foundation, Inc.
;; Author: Michael Kifer <[email protected]>
;; Created: February 2, 1994
;; Keywords: comparing, merging, patching, tools, unix
-(defconst ediff-version "2.78" "The current version of Ediff")
-(defconst ediff-date "May 18, 2003" "Date of last update")
+(defconst ediff-version "2.80" "The current version of Ediff")
+(defconst ediff-date "February 19, 2005" "Date of last update")
;; This file is part of GNU Emacs.
@@ -1080,8 +1080,11 @@ lines. For small regions, use `ediff-regions-wordwise'."
(defsubst ediff-merge-on-startup ()
(ediff-do-merge 0)
- (ediff-with-current-buffer ediff-buffer-C
- (set-buffer-modified-p nil)))
+ ;; Can't remember why this is here, but it may cause the automatically merged
+ ;; buffer to be lost. So, keep the buffer modified.
+ ;;(ediff-with-current-buffer ediff-buffer-C
+ ;; (set-buffer-modified-p nil))
+ )
;;;###autoload
(defun ediff-merge-files (file-A file-B
diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el
index eb5e5ede4c..8023336b18 100644
--- a/lisp/emulation/viper-cmd.el
+++ b/lisp/emulation/viper-cmd.el
@@ -1063,7 +1063,7 @@ as a Meta key and any number of multiple escapes is allowed."
;; call the actual function to execute ESC (if no other symbols followed)
;; or the key bound to the ESC sequence (if the sequence was issued
- ;; with very short delay between characters.
+ ;; with very short delay between characters).
(if (eq cmd 'viper-intercept-ESC-key)
(setq cmd
(cond ((eq viper-current-state 'vi-state)
@@ -1529,7 +1529,8 @@ as a Meta key and any number of multiple escapes is allowed."
nil)
(defun viper-exec-buffer-search (m-com com)
- (setq viper-s-string (buffer-substring (point) viper-com-point))
+ (setq viper-s-string
+ (regexp-quote (buffer-substring (point) viper-com-point)))
(setq viper-s-forward t)
(setq viper-search-history (cons viper-s-string viper-search-history))
(setq viper-intermediate-command 'viper-exec-buffer-search)
@@ -1982,6 +1983,16 @@ Undo previous insertion and inserts new."
(let ((hook (if viper-vi-style-in-minibuffer
'viper-change-state-to-insert
'viper-change-state-to-emacs)))
+ ;; making buffer-local variables so that normal buffers won't affect the
+ ;; minibuffer and vice versa. Otherwise, command arguments will affect
+ ;; minibuffer ops and insertions from the minibuffer will change those in
+ ;; the normal buffers
+ (make-local-variable 'viper-d-com)
+ (make-local-variable 'viper-last-insertion)
+ (make-local-variable 'viper-command-ring)
+ (setq viper-d-com nil
+ viper-last-insertion nil
+ viper-command-ring nil)
(funcall hook)
))
@@ -2707,7 +2718,7 @@ On reaching beginning of line, stop and signal error."
(viper-backward-char-carefully)
(if (looking-at "\n")
(viper-skip-all-separators-backward 'within-line)
- (or (bobp) (forward-char)))))
+ (or (viper-looking-at-separator) (forward-char)))))
(defun viper-forward-word-kernel (val)
@@ -3630,33 +3641,39 @@ the Emacs binding of `/'."
(setq msg "Search style remains unchanged")))
(princ msg t)))
-(defun viper-set-searchstyle-toggling-macros (unset)
+(defun viper-set-searchstyle-toggling-macros (unset &optional major-mode)
"Set the macros for toggling the search style in Viper's vi-state.
The macro that toggles case sensitivity is bound to `//', and the one that
toggles regexp search is bound to `///'.
-With a prefix argument, this function unsets the macros. "
+With a prefix argument, this function unsets the macros.
+If MAJOR-MODE is set, set the macros only in that major mode."
(interactive "P")
- (or noninteractive
- (if (not unset)
- (progn
- ;; toggle case sensitivity in search
- (viper-record-kbd-macro
- "//" 'vi-state
- [1 (meta x) v i p e r - t o g g l e - s e a r c h - s t y l e return]
- 't)
- ;; toggle regexp/vanila search
- (viper-record-kbd-macro
- "///" 'vi-state
- [2 (meta x) v i p e r - t o g g l e - s e a r c h - s t y l e return]
- 't)
- (if (interactive-p)
- (message
- "// and /// now toggle case-sensitivity and regexp search")))
- (viper-unrecord-kbd-macro "//" 'vi-state)
- (sit-for 2)
- (viper-unrecord-kbd-macro "///" 'vi-state))))
-
-
+ (let (scope)
+ (if (and major-mode (symbolp major-mode))
+ (setq scope major-mode)
+ (setq scope 't))
+ (or noninteractive
+ (if (not unset)
+ (progn
+ ;; toggle case sensitivity in search
+ (viper-record-kbd-macro
+ "//" 'vi-state
+ [1 (meta x) v i p e r - t o g g l e - s e a r c h - s t y l e return]
+ scope)
+ ;; toggle regexp/vanila search
+ (viper-record-kbd-macro
+ "///" 'vi-state
+ [2 (meta x) v i p e r - t o g g l e - s e a r c h - s t y l e return]
+ scope)
+ (if (interactive-p)
+ (message
+ "// and /// now toggle case-sensitivity and regexp search")))
+ (viper-unrecord-kbd-macro "//" 'vi-state)
+ (sit-for 2)
+ (viper-unrecord-kbd-macro "///" 'vi-state)))
+ ))
+
+
(defun viper-set-parsing-style-toggling-macro (unset)
"Set `%%%' to be a macro that toggles whether comment fields should be parsed for matching parentheses.
This is used in conjunction with the `%' command.
@@ -4112,7 +4129,8 @@ Null string will repeat previous search."
(interactive)
(if (and viper-ex-style-editing (bolp))
(beep 1)
- (delete-backward-char 1 t)))
+ ;; don't put on kill ring
+ (delete-backward-char 1 nil)))
(defun viper-del-backward-char-in-replace ()
@@ -4124,13 +4142,15 @@ cursor move past the beginning of line."
(interactive)
(cond (viper-delete-backwards-in-replace
(cond ((not (bolp))
- (delete-backward-char 1 t))
+ ;; don't put on kill ring
+ (delete-backward-char 1 nil))
(viper-ex-style-editing
(beep 1))
((bobp)
(beep 1))
(t
- (delete-backward-char 1 t))))
+ ;; don't put on kill ring
+ (delete-backward-char 1 nil))))
(viper-ex-style-editing
(if (bolp)
(beep 1)
diff --git a/lisp/emulation/viper-ex.el b/lisp/emulation/viper-ex.el
index c94edf54bc..90b006ffb6 100644
--- a/lisp/emulation/viper-ex.el
+++ b/lisp/emulation/viper-ex.el
@@ -1,6 +1,6 @@
;;; viper-ex.el --- functions implementing the Ex commands for Viper
-;; Copyright (C) 1994, 95, 96, 97, 98, 2000, 01, 02, 04 Free Software Foundation, Inc.
+;; Copyright (C) 1994, 95, 96, 97, 98, 2000, 01, 02, 04, 05 Free Software Foundation, Inc.
;; Author: Michael Kifer <[email protected]>
diff --git a/lisp/emulation/viper-init.el b/lisp/emulation/viper-init.el
index 2a13f00535..4f08f1b6cc 100644
--- a/lisp/emulation/viper-init.el
+++ b/lisp/emulation/viper-init.el
@@ -70,6 +70,16 @@
window-system
))
+(defun viper-color-display-p ()
+ (condition-case nil
+ (viper-cond-compile-for-xemacs-or-emacs
+ (eq (device-class (selected-device)) 'color) ; xemacs form
+ (if (fboundp 'display-color-p) ; emacs form
+ (display-color-p)
+ (x-display-color-p))
+ )
+ (error nil)))
+
;; in XEmacs: device-type is tty on tty and stream in batch.
(defun viper-window-display-p ()
(and (viper-device-type) (not (memq (viper-device-type) '(tty stream pc)))))
@@ -97,6 +107,7 @@ In all likelihood, you don't need to bother with this setting."
(defun viper-has-face-support-p ()
(cond ((viper-window-display-p))
(viper-force-faces)
+ ((viper-color-display-p))
(viper-emacs-p (memq (viper-device-type) '(pc)))
(viper-xemacs-p (memq (viper-device-type) '(tty pc)))))
diff --git a/lisp/emulation/viper-keym.el b/lisp/emulation/viper-keym.el
index 146b54b703..e5074b9583 100644
--- a/lisp/emulation/viper-keym.el
+++ b/lisp/emulation/viper-keym.el
@@ -455,6 +455,10 @@ Useful in some modes, such as Gnus, MH, etc.")
(define-key viper-dired-modifier-map ":" 'viper-ex)
(define-key viper-dired-modifier-map "/" 'viper-search-forward)
+(defvar viper-gnus-modifier-map (make-sparse-keymap)
+ "This map modifies Gnus behavior.")
+(define-key viper-gnus-modifier-map ":" 'viper-ex)
+
;;; Code
diff --git a/lisp/emulation/viper-macs.el b/lisp/emulation/viper-macs.el
index c6a3fdfe1f..df0e37e7c2 100644
--- a/lisp/emulation/viper-macs.el
+++ b/lisp/emulation/viper-macs.el
@@ -329,6 +329,8 @@ a key is a symbol, e.g., `a', `\\1', `f2', etc., or a list, e.g.,
;; Accepts as macro names: strings and vectors.
;; strings must be strings of characters; vectors must be vectors of keys
;; in canonic form. The canonic form is essentially the form used in XEmacs
+;; More general definitions are inherited by more specific scopes:
+;; global->major mode->buffer. More specific definitions override more general
(defun viper-record-kbd-macro (macro-name state macro-body &optional scope)
"Record a Vi macro. Can be used in `.viper' file to define permanent macros.
MACRO-NAME is a string of characters or a vector of keys. STATE is
@@ -451,22 +453,22 @@ If SCOPE is nil, the user is asked to specify the scope."
(list (list (cons scope nil)) nil (cons t nil))))))
(setq old-elt (assoc macro-name (eval macro-alist-var)))
- (if (null old-elt)
- (progn
- ;; insert new-elt in macro-alist-var and keep the list sorted
- (define-key
- keymap
- (vector (viper-key-to-emacs-key (aref macro-name 0)))
- 'viper-exec-mapped-kbd-macro)
- (setq lis (eval macro-alist-var))
- (while (and lis (string< (viper-array-to-string (car (car lis)))
- (viper-array-to-string macro-name)))
- (setq lis2 (cons (car lis) lis2))
- (setq lis (cdr lis)))
-
- (setq lis2 (reverse lis2))
- (set macro-alist-var (append lis2 (cons new-elt lis)))
- (setq old-elt new-elt)))
+ (if (null old-elt)
+ (progn
+ ;; insert new-elt in macro-alist-var and keep the list sorted
+ (define-key
+ keymap
+ (vector (viper-key-to-emacs-key (aref macro-name 0)))
+ 'viper-exec-mapped-kbd-macro)
+ (setq lis (eval macro-alist-var))
+ (while (and lis (string< (viper-array-to-string (car (car lis)))
+ (viper-array-to-string macro-name)))
+ (setq lis2 (cons (car lis) lis2))
+ (setq lis (cdr lis)))
+
+ (setq lis2 (reverse lis2))
+ (set macro-alist-var (append lis2 (cons new-elt lis)))
+ (setq old-elt new-elt)))
(setq old-sub-elt
(cond ((eq scope t) (viper-kbd-global-pair old-elt))
((symbolp scope) (assoc scope (viper-kbd-mode-alist old-elt)))
@@ -484,6 +486,11 @@ If SCOPE is nil, the user is asked to specify the scope."
;; macro name must be a vector of viper-style keys
+;; viper-unrecord-kbd-macro doesn't have scope. Macro definitions are inherited
+;; from global -> major mode -> buffer
+;; More specific definition overrides more general
+;; Can't unrecord definition for more specific, if a more general definition is
+;; in effect
(defun viper-unrecord-kbd-macro (macro-name state)
"Delete macro MACRO-NAME from Viper STATE.
MACRO-NAME must be a vector of viper-style keys. This command is used by Viper
@@ -546,7 +553,7 @@ name from there."
(setq macro-pair mode-mapping)
(message "%S is unmapped for %s in %S"
(viper-display-macro macro-name) state-name major-mode))
- ((cdr (setq macro-pair (viper-kbd-global-pair macro-entry)))
+ ((cdr (setq macro-pair global-mapping))
(message
"Global mapping for %S in %s is removed"
(viper-display-macro macro-name) state-name))
@@ -560,7 +567,7 @@ name from there."
(progn
(set macro-alist-var (delq macro-entry (eval macro-alist-var)))
(if (viper-can-release-key (aref macro-name 0)
- (eval macro-alist-var))
+ (eval macro-alist-var))
(define-key
keymap
(vector (viper-key-to-emacs-key (aref macro-name 0)))
diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el
index 5e533e5f54..527a04084e 100644
--- a/lisp/emulation/viper-util.el
+++ b/lisp/emulation/viper-util.el
@@ -662,14 +662,8 @@
;; define remote file test
-(or (fboundp 'viper-file-remote-p) ; user supplied his own function: use it
- (defun viper-file-remote-p (file-name)
- (car (cond ((featurep 'efs-auto) (efs-ftp-path file-name))
- ((fboundp 'file-remote-p) (file-remote-p file-name))
- (t (require 'ange-ftp)
- ;; Can happen only in Emacs, since XEmacs has file-remote-p
- (ange-ftp-ftp-name file-name))))))
-
+(defun viper-file-remote-p (file-name)
+ (file-remote-p file-name))
;; This is a simple-minded check for whether a file is under version control.
diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el
index 15ec74b41f..be5a8e3467 100644
--- a/lisp/emulation/viper.el
+++ b/lisp/emulation/viper.el
@@ -3,12 +3,12 @@
;; and a venomous VI PERil.
;; Viper Is also a Package for Emacs Rebels.
-;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02 Free Software Foundation, Inc.
+;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02, 05 Free Software Foundation, Inc.
;; Author: Michael Kifer <[email protected]>
;; Keywords: emulations
-(defconst viper-version "3.11.2 of January 4, 2002"
+(defconst viper-version "3.11.4 of February 19, 2005"
"The current version of Viper")
;; This file is part of GNU Emacs.
@@ -466,7 +466,7 @@ unless it is coming up in a wrong Viper state."
(nth 0 triple) (nth 1 triple) (eval (nth 2 triple))))
viper-major-mode-modifier-list))
-;; We change standard bindings in some major mode, making them slightly
+;; We change standard bindings in some major modes, making them slightly
;; different than in "normal" vi/insert/emacs states
(defcustom viper-major-mode-modifier-list
'((help-mode emacs-state viper-slash-and-colon-map)
@@ -482,8 +482,8 @@ unless it is coming up in a wrong Viper state."
(dired-mode emacs-state viper-dired-modifier-map)
(tar-mode emacs-state viper-slash-and-colon-map)
(mh-folder-mode emacs-state viper-slash-and-colon-map)
- (gnus-group-mode emacs-state viper-slash-and-colon-map)
- (gnus-summary-mode emacs-state viper-slash-and-colon-map)
+ (gnus-group-mode emacs-state viper-gnus-modifier-map)
+ (gnus-summary-mode emacs-state viper-gnus-modifier-map)
(Info-mode emacs-state viper-slash-and-colon-map)
(Buffer-menu-mode emacs-state viper-slash-and-colon-map)
)
diff --git a/lisp/faces.el b/lisp/faces.el
index 1f77acd3cf..36f207b5da 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -1881,6 +1881,9 @@ created."
(defface minibuffer-prompt '((((background dark)) :foreground "cyan")
+ ;; Don't use blue because many users of
+ ;; the MS-DOS port customize their
+ ;; foreground color to be blue.
(((type pc)) :foreground "magenta")
(t :foreground "dark blue"))
"Face for minibuffer prompts."
@@ -2048,6 +2051,8 @@ Note: Other faces cannot inherit from the cursor face."
:group 'basic-faces)
(defface escape-glyph '((((background dark)) :foreground "cyan")
+ ;; See the comment in minibuffer-prompt for
+ ;; the reason not to use blue on MS-DOS.
(((type pc)) :foreground "magenta")
(t :foreground "blue"))
"Face for characters displayed as ^-sequences or \-sequences."
diff --git a/lisp/frame.el b/lisp/frame.el
index 2aff4860cf..5da549fd73 100644
--- a/lisp/frame.el
+++ b/lisp/frame.el
@@ -1,6 +1,6 @@
;;; frame.el --- multi-frame management independent of window systems
-;; Copyright (C) 1993, 1994, 1996, 1997, 2000, 2001, 2003, 2004
+;; Copyright (C) 1993, 1994, 1996, 1997, 2000, 2001, 2003, 2004, 2005
;; Free Software Foundation, Inc.
;; Maintainer: FSF
@@ -1256,35 +1256,11 @@ The function `blink-cursor-start' is called when the timer fires.")
This timer calls `blink-cursor-timer-function' every
`blink-cursor-interval' seconds.")
-;; The strange sequence below is meant to set both the right temporary
-;; value and the right "standard expression" , according to Custom,
-;; for blink-cursor-mode. We do not know the standard _evaluated_
-;; value yet, because the standard expression uses values that are not
-;; yet set. Evaluating it now would yield an error, but we make sure
-;; that it is not evaluated, by ensuring that blink-cursor-mode is set
-;; before the defcustom is evaluated and by using the right :initialize
-;; function. The correct evaluated standard value will be installed
-;; in startup.el using exactly the same expression as in the defcustom.
-(defvar blink-cursor-mode)
-(unless (boundp 'blink-cursor-mode) (setq blink-cursor-mode nil))
-(defcustom blink-cursor-mode
- (not (or noninteractive
- emacs-quick-startup
- (eq system-type 'ms-dos)
- (not (memq window-system '(x w32)))))
- "*Non-nil means Blinking Cursor mode is active."
- :group 'cursor
- :tag "Blinking cursor"
- :type 'boolean
- :initialize 'custom-initialize-set
- :set #'(lambda (symbol value)
- (set-default symbol value)
- (blink-cursor-mode (or value 0))))
-
-(defvaralias 'blink-cursor 'blink-cursor-mode)
-(make-obsolete-variable 'blink-cursor 'blink-cursor-mode "22.1")
-
-(defun blink-cursor-mode (arg)
+;; We do not know the standard _evaluated_ value yet, because the standard
+;; expression uses values that are not yet set. The correct evaluated
+;; standard value will be installed in startup.el using exactly the same
+;; expression as in the defcustom.
+(define-minor-mode blink-cursor-mode
"Toggle blinking cursor mode.
With a numeric argument, turn blinking cursor mode on iff ARG is positive.
When blinking cursor mode is enabled, the cursor of the selected
@@ -1293,27 +1269,27 @@ window blinks.
Note that this command is effective only when Emacs
displays through a window system, because then Emacs does its own
cursor display. On a text-only terminal, this is not implemented."
- (interactive "P")
- (let ((on-p (if (null arg)
- (not blink-cursor-mode)
- (> (prefix-numeric-value arg) 0))))
- (if blink-cursor-idle-timer
- (cancel-timer blink-cursor-idle-timer))
- (if blink-cursor-timer
- (cancel-timer blink-cursor-timer))
- (setq blink-cursor-idle-timer nil
- blink-cursor-timer nil
- blink-cursor-mode nil)
- (if on-p
- (progn
- ;; Hide the cursor.
- ;(internal-show-cursor nil nil)
- (setq blink-cursor-idle-timer
- (run-with-idle-timer blink-cursor-delay
- blink-cursor-delay
- 'blink-cursor-start))
- (setq blink-cursor-mode t))
- (internal-show-cursor nil t))))
+ :init-value (not (or noninteractive
+ emacs-quick-startup
+ (eq system-type 'ms-dos)
+ (not (memq window-system '(x w32)))))
+ :global t
+ (if blink-cursor-idle-timer (cancel-timer blink-cursor-idle-timer))
+ (if blink-cursor-timer (cancel-timer blink-cursor-timer))
+ (setq blink-cursor-idle-timer nil
+ blink-cursor-timer nil)
+ (if blink-cursor-mode
+ (progn
+ ;; Hide the cursor.
+ ;;(internal-show-cursor nil nil)
+ (setq blink-cursor-idle-timer
+ (run-with-idle-timer blink-cursor-delay
+ blink-cursor-delay
+ 'blink-cursor-start)))
+ (internal-show-cursor nil t)))
+
+(defvaralias 'blink-cursor 'blink-cursor-mode)
+(make-obsolete-variable 'blink-cursor 'blink-cursor-mode "22.1")
(defun blink-cursor-start ()
"Timer function called from the timer `blink-cursor-idle-timer'.
@@ -1379,5 +1355,5 @@ Use Custom to set this variable to get the display updated."
(provide 'frame)
-;;; arch-tag: 82979c70-b8f2-4306-b2ad-ddbd6b328b56
+;; arch-tag: 82979c70-b8f2-4306-b2ad-ddbd6b328b56
;;; frame.el ends here
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index bc8b89a251..3a9a24b57c 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -1,3 +1,40 @@
+2005-02-21 Reiner Steib <[email protected]>
+
+ * gnus-art.el (gnus-parse-news-url, gnus-button-handle-news):
+ Handle news URL with given port correctly.
+
+2005-02-19 Katsumi Yamaoka <[email protected]>
+
+ * gnus-msg.el (gnus-copy-article-buffer): Quote decoded words
+ containing special characters.
+
+ * gnus-sum.el (gnus-summary-edit-article): Ditto.
+
+ * mml.el (mime-to-mml): Ditto.
+
+ * rfc2047.el (rfc2047-encode-parameter): Use ietf-drums-tspecials.
+ (rfc2047-quote-decoded-words-containing-tspecials): New variable.
+ (rfc2047-decode-region): Quote decoded words containing special
+ characters when rfc2047-quote-decoded-words-containing-tspecials
+ is non-nil.
+
+2005-02-16 Teodor Zlatanov <[email protected]>
+
+ * gnus-registry.el (gnus-registry-delete-group): minor bug fix
+
+ * gnus.el (gnus-install-group-spam-parameters): Doc fix.
+
+2005-02-15 Simon Josefsson <[email protected]>
+
+ * nnimap.el (nnimap-debug): Doc fix.
+
+ * imap.el (imap-debug): Doc fix.
+
+2005-02-14 Reiner Steib <[email protected]>
+
+ * gnus-group.el (gnus-group-make-doc-group): Mention prefix
+ argument in doc string. Make query for type more clear.
+
2005-02-13 Reiner Steib <[email protected]>
* gnus.el (gnus-group-startup-message): Search for gnus images in
diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el
index 0d0da23ea5..0cfc433bd5 100644
--- a/lisp/gnus/gnus-art.el
+++ b/lisp/gnus/gnus-art.el
@@ -6648,15 +6648,18 @@ specified by `gnus-button-alist'."
(cons fun args)))))))
(defun gnus-parse-news-url (url)
- (let (scheme server group message-id articles)
+ (let (scheme server port group message-id articles)
(with-temp-buffer
(insert url)
(goto-char (point-min))
(when (looking-at "\\([A-Za-z]+\\):")
(setq scheme (match-string 1))
(goto-char (match-end 0)))
- (when (looking-at "//\\([^/]+\\)/")
+ (when (looking-at "//\\([^:/]+\\)\\(:?\\)\\([0-9]+\\)?/")
(setq server (match-string 1))
+ (setq port (if (stringp (match-string 3))
+ (string-to-number (match-string 3))
+ (match-string 3)))
(goto-char (match-end 0)))
(cond
@@ -6669,18 +6672,19 @@ specified by `gnus-button-alist'."
(setq group (match-string 1)))
(t
(error "Unknown news URL syntax"))))
- (list scheme server group message-id articles)))
+ (list scheme server port group message-id articles)))
(defun gnus-button-handle-news (url)
"Fetch a news URL."
- (destructuring-bind (scheme server group message-id articles)
+ (destructuring-bind (scheme server port group message-id articles)
(gnus-parse-news-url url)
(cond
(message-id
(save-excursion
(set-buffer gnus-summary-buffer)
(if server
- (let ((gnus-refer-article-method (list (list 'nntp server))))
+ (let ((gnus-refer-article-method (list (list 'nntp server)))
+ (nntp-port-number (or port "nntp")))
(gnus-summary-refer-article message-id))
(gnus-summary-refer-article message-id))))
(group
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el
index 2d6137c0bb..5892235dea 100644
--- a/lisp/gnus/gnus-group.el
+++ b/lisp/gnus/gnus-group.el
@@ -2502,7 +2502,9 @@ group already exists:
(gnus-group-position-point))
(defun gnus-group-make-doc-group (file type)
- "Create a group that uses a single file as the source."
+ "Create a group that uses a single file as the source.
+
+If called with a prefix argument, ask for the file type."
(interactive
(list (read-file-name "File name: ")
(and current-prefix-arg 'ask)))
@@ -2511,7 +2513,7 @@ group already exists:
char found)
(while (not found)
(message
- "%sFile type (mbox, babyl, digest, forward, mmdf, guess) [mbdfag]: "
+ "%sFile type (mbox, babyl, digest, forward, mmdf, guess) [m, b, d, f, a, g]: "
err)
(setq found (cond ((= (setq char (read-char)) ?m) 'mbox)
((= char ?b) 'babyl)
diff --git a/lisp/gnus/gnus-msg.el b/lisp/gnus/gnus-msg.el
index 65b3d78aca..a71dce313d 100644
--- a/lisp/gnus/gnus-msg.el
+++ b/lisp/gnus/gnus-msg.el
@@ -876,7 +876,8 @@ header line with the old Message-ID."
;; Decode charsets.
(let ((gnus-article-decode-hook
(delq 'article-decode-charset
- (copy-sequence gnus-article-decode-hook))))
+ (copy-sequence gnus-article-decode-hook)))
+ (rfc2047-quote-decoded-words-containing-tspecials t))
(run-hooks 'gnus-article-decode-hook)))))
gnus-article-copy)))
diff --git a/lisp/gnus/gnus-registry.el b/lisp/gnus/gnus-registry.el
index 0971fea548..3b7d6e43b4 100644
--- a/lisp/gnus/gnus-registry.el
+++ b/lisp/gnus/gnus-registry.el
@@ -606,7 +606,9 @@ Returns the first place where the trail finds a group name."
(when gnus-registry-trim-articles-without-groups
(unless (gnus-registry-group-count id)
(gnus-registry-delete-id id)))
- (gnus-registry-store-extra-entry id 'mtime (current-time)))))
+ ;; is this ID still in the registry?
+ (when (gethash id gnus-registry-hashtb)
+ (gnus-registry-store-extra-entry id 'mtime (current-time))))))
(defun gnus-registry-delete-id (id)
"Delete a message ID from the registry."
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el
index 1e7e962e32..5e276fcf91 100644
--- a/lisp/gnus/gnus-sum.el
+++ b/lisp/gnus/gnus-sum.el
@@ -9485,7 +9485,8 @@ groups."
`(lambda ()
(let ((mbl mml-buffer-list))
(setq mml-buffer-list nil)
- (mime-to-mml ,'current-handles)
+ (let ((rfc2047-quote-decoded-words-containing-tspecials t))
+ (mime-to-mml ,'current-handles))
(let ((mbl1 mml-buffer-list))
(setq mml-buffer-list mbl)
(set (make-local-variable 'mml-buffer-list) mbl1))
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el
index f5dcd296d2..fa1da9e82f 100644
--- a/lisp/gnus/gnus.el
+++ b/lisp/gnus/gnus.el
@@ -1819,11 +1819,12 @@ registry.")
:variable gnus-spam-newsgroup-contents
:variable-default nil
:variable-document
- "*Groups in which to automatically mark new articles as spam on
-summary entry. If non-nil, this should be a list of group name
-regexps that should match all groups in which to do automatic spam
-tagging, associated with a classification (spam, ham, or neither).
-This only makes sense for mail groups."
+ "*Group classification (spam, ham, or neither). Only
+meaningful when spam.el is loaded. If non-nil, this should be a
+list of group name regexps associated with a classification for
+each one. In spam groups, new articles are marked as spam on
+summary entry. There is other behavior associated with ham and
+no classification when spam.el is loaded - see the manual."
:variable-group spam
:variable-type '(repeat
(list :tag "Group contents spam/ham classification"
@@ -1840,7 +1841,9 @@ This only makes sense for mail groups."
(const :tag "Unclassified" nil)))
:parameter-document
"The spam classification (spam, ham, or neither) of this group.
-When a spam group is entered, all unread articles are marked as spam.")
+When a spam group is entered, all unread articles are marked as
+spam. There is other behavior associated with ham and no
+classification when spam.el is loaded - see the manual.")
(defvar gnus-group-spam-exit-processor-ifile "ifile"
"OBSOLETE: The ifile summary exit spam processor.")
diff --git a/lisp/gnus/imap.el b/lisp/gnus/imap.el
index aba0e88b92..c7f9d60339 100644
--- a/lisp/gnus/imap.el
+++ b/lisp/gnus/imap.el
@@ -250,7 +250,11 @@ variable unless you are comfortable with that."
:type 'boolean)
(defcustom imap-debug nil
- "If non-nil, random debug spews are placed in *imap-debug* buffer."
+ "If non-nil, random debug spews are placed in *imap-debug* buffer.
+Note that username, passwords and other privacy sensitive
+information (such as e-mail) may be stored in the *imap-debug*
+buffer. It is not written to disk, however. Do not enable this
+variable unless you are comfortable with that."
:group 'imap
:type 'boolean)
diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el
index 010acc63a2..0cc2b0814f 100644
--- a/lisp/gnus/mml.el
+++ b/lisp/gnus/mml.el
@@ -709,7 +709,8 @@ If HANDLES is non-nil, use it instead reparsing the buffer."
;; First decode the head.
(save-restriction
(message-narrow-to-head)
- (mail-decode-encoded-word-region (point-min) (point-max)))
+ (let ((rfc2047-quote-decoded-words-containing-tspecials t))
+ (mail-decode-encoded-word-region (point-min) (point-max))))
(unless handles
(setq handles (mm-dissect-buffer t)))
(goto-char (point-min))
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el
index c3afd6381c..59b0178de4 100644
--- a/lisp/gnus/nnimap.el
+++ b/lisp/gnus/nnimap.el
@@ -1,5 +1,5 @@
;;; nnimap.el --- imap backend for Gnus
-;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004
+;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
;; Free Software Foundation, Inc.
;; Author: Simon Josefsson <[email protected]>
@@ -409,7 +409,11 @@ If this is 'imap-mailbox-lsub, then use a server-side subscription list to
restrict visible folders.")
(defcustom nnimap-debug nil
- "If non-nil, random debug spews are placed in *nnimap-debug* buffer."
+ "If non-nil, random debug spews are placed in *nnimap-debug* buffer.
+Note that username, passwords and other privacy sensitive
+information (such as e-mail) may be stored in the *nnimap-debug*
+buffer. It is not written to disk, however. Do not enable this
+variable unless you are comfortable with that."
:group 'nnimap
:type 'boolean)
diff --git a/lisp/gnus/rfc2047.el b/lisp/gnus/rfc2047.el
index e5022897aa..ab00edb912 100644
--- a/lisp/gnus/rfc2047.el
+++ b/lisp/gnus/rfc2047.el
@@ -1,5 +1,7 @@
;;; rfc2047.el --- functions for encoding and decoding rfc2047 messages
-;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2005 Free Software Foundation, Inc.
+
+;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005
+;; Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <[email protected]>
;; MORIOKA Tomohiko <[email protected]>
@@ -50,6 +52,7 @@ Value is what BODY returns."
(require 'qp)
(require 'mm-util)
+(require 'ietf-drums)
;; Fixme: Avoid this (used for mail-parse-charset) mm dependence on gnus.
(require 'mail-prsvr)
(require 'base64)
@@ -639,6 +642,9 @@ By default, the region is treated as containing addresses (see
"=\\?\\([^][\000-\040()<>@,\;:\\\"/?.=]+\\)\\?\\(B\\|Q\\)\
\\?\\([!->@-~ +]*\\)\\?="))
+(defvar rfc2047-quote-decoded-words-containing-tspecials nil
+ "If non-nil, quote decoded words containing special characters.")
+
;; Fixme: This should decode in place, not cons intermediate strings.
;; Also check whether it needs to worry about delimiting fields like
;; encoding.
@@ -673,14 +679,66 @@ By default, the region is treated as containing addresses (see
(insert (rfc2047-parse-and-decode
(prog1
(match-string 0)
- (delete-region (match-beginning 0) (match-end 0)))))
- ;; Remove newlines between decoded words, though such things
- ;; essentially must not be there.
+ (delete-region e (match-end 0)))))
+ (while (looking-at rfc2047-encoded-word-regexp)
+ (insert (rfc2047-parse-and-decode
+ (prog1
+ (match-string 0)
+ (delete-region (point) (match-end 0))))))
(save-restriction
(narrow-to-region e (point))
(goto-char e)
+ ;; Remove newlines between decoded words, though such
+ ;; things essentially must not be there.
(while (re-search-forward "[\n\r]+" nil t)
(replace-match " "))
+ ;; Quote decoded words if there are special characters
+ ;; which might violate RFC2822.
+ (when (and rfc2047-quote-decoded-words-containing-tspecials
+ (let ((regexp (car (rassq
+ 'address-mime
+ rfc2047-header-encoding-alist))))
+ (when regexp
+ (save-restriction
+ (widen)
+ (beginning-of-line)
+ (while (and (memq (char-after) '(? ?\t))
+ (zerop (forward-line -1))))
+ (looking-at regexp)))))
+ (let (quoted)
+ (goto-char e)
+ (skip-chars-forward " \t")
+ (setq start (point))
+ (setq quoted (eq (char-after) ?\"))
+ (goto-char (point-max))
+ (skip-chars-backward " \t")
+ (if (setq quoted (and quoted
+ (> (point) (1+ start))
+ (eq (char-before) ?\")))
+ (progn
+ (backward-char)
+ (setq start (1+ start)
+ end (point-marker)))
+ (setq end (point-marker)))
+ (goto-char start)
+ (while (search-forward "\"" end t)
+ (when (prog2
+ (backward-char)
+ (zerop (% (skip-chars-backward "\\\\") 2))
+ (goto-char (match-beginning 0)))
+ (insert "\\"))
+ (forward-char))
+ (when (and (not quoted)
+ (progn
+ (goto-char start)
+ (re-search-forward
+ (concat "[" ietf-drums-tspecials "]")
+ end t)))
+ (goto-char start)
+ (insert "\"")
+ (goto-char end)
+ (insert "\""))
+ (set-marker end nil)))
(goto-char (point-max)))
(when (and (mm-multibyte-p)
mail-parse-charset
diff --git a/lisp/isearch.el b/lisp/isearch.el
index f1cb55e7fc..d67a27e236 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -533,6 +533,11 @@ Type \\[isearch-quote-char] to quote control character to search for it.
\\[isearch-abort] when search is successful aborts and moves point to\
starting point.
+Type \\[isearch-query-replace] to start `query-replace' with string to\
+replace from last search string.
+Type \\[isearch-query-replace-regexp] to start `query-replace-regexp'\
+with string to replace from last search string..
+
Type \\[isearch-toggle-case-fold] to toggle search case-sensitivity.
Type \\[isearch-toggle-regexp] to toggle regular-expression mode.
Type \\[isearch-edit-string] to edit the search string in the minibuffer.
diff --git a/lisp/log-view.el b/lisp/log-view.el
index 51ca8907db..c153cbdbb6 100644
--- a/lisp/log-view.el
+++ b/lisp/log-view.el
@@ -1,6 +1,6 @@
;;; log-view.el --- Major mode for browsing RCS/CVS/SCCS log output
-;; Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
+;; Copyright (C) 1999, 2000, 2001, 2005 Free Software Foundation, Inc.
;; Author: Stefan Monnier <[email protected]>
;; Keywords: rcs sccs cvs log version-control
@@ -85,7 +85,7 @@
"\\|SCCS/s\\.\\(.+\\):"
"\\)\n"))
;; In RCS, a locked revision will look like "revision N.M\tlocked by: FOO".
-(defconst log-view-message-re "^\\(revision \\([.0-9]+\\)\\(?:\t.*\\)?\\|rev \\([0-9]+\\): .*\\|D \\([.0-9]+\\) .*\\)$")
+(defconst log-view-message-re "^\\(revision \\([.0-9]+\\)\\(?:\t.*\\)?\\|r\\([0-9]+\\) | .* | .*\\|D \\([.0-9]+\\) .*\\)$")
(defconst log-view-font-lock-keywords
`((,log-view-file-re
@@ -206,5 +206,5 @@ were the region starts and ends."
(provide 'log-view)
-;;; arch-tag: 0d64220b-ce7e-4f62-9c2a-6b04c2f81f4f
+;; arch-tag: 0d64220b-ce7e-4f62-9c2a-6b04c2f81f4f
;;; log-view.el ends here
diff --git a/lisp/mouse.el b/lisp/mouse.el
index 96c1b85f98..5efcca1bd5 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -769,6 +769,8 @@ If the click is in the echo area, display the `*Messages*' buffer."
(defun mouse-on-link-p (pos)
"Return non-nil if POS is on a link in the current buffer.
+POS must be a buffer position in the current buffer or an mouse
+event location in the selected window, see `event-start'.
A clickable link is identified by one of the following methods:
@@ -787,7 +789,7 @@ is a non-nil `mouse-face' property at POS. Return t in this case.
- If the value is a function, FUNC, POS is inside a link if
the call \(FUNC POS) returns non-nil. Return the return value
-from that call.
+from that call. Arg is \(posn-point POS) if POS is a mouse event,
- Otherwise, return the value itself.
@@ -803,17 +805,22 @@ click is the local or global binding of that event.
- Otherwise, the mouse-1 event is translated into a mouse-2 event
at the same position."
- (let ((action
- (or (get-char-property pos 'follow-link)
- (save-excursion
- (goto-char pos)
- (key-binding [follow-link] nil t)))))
- (cond
- ((eq action 'mouse-face)
- (and (get-char-property pos 'mouse-face) t))
- ((functionp action)
- (funcall action pos))
- (t action))))
+ (if (consp pos)
+ (setq pos (and (eq (selected-window) (posn-window pos))
+ (posn-point pos))))
+ (when pos
+ (let ((action
+ (or (get-char-property pos 'follow-link)
+ (save-excursion
+ (goto-char pos)
+ (key-binding [follow-link] nil t)))))
+ (cond
+ ((eq action 'mouse-face)
+ (and (get-char-property pos 'mouse-face) t))
+ ((functionp action)
+ (funcall action pos))
+ (t action)))))
+
(defun mouse-drag-region-1 (start-event)
(mouse-minibuffer-check start-event)
@@ -831,7 +838,9 @@ at the same position."
(nth 3 bounds)
;; Don't count the mode line.
(1- (nth 3 bounds))))
- on-link remap-double-click
+ (on-link (and mouse-1-click-follows-link
+ (eq start-window (selected-window))))
+ remap-double-click
(click-count (1- (event-click-count start-event))))
(setq mouse-selection-click-count click-count)
(setq mouse-selection-click-count-buffer (current-buffer))
@@ -841,7 +850,7 @@ at the same position."
(if (< (point) start-point)
(goto-char start-point))
(setq start-point (point))
- (setq on-link (and mouse-1-click-follows-link
+ (setq on-link (and on-link
(mouse-on-link-p start-point)))
(setq remap-double-click (and on-link
(eq mouse-1-click-follows-link 'double)
diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el
index 6e679876ee..78c8e97626 100644
--- a/lisp/net/browse-url.el
+++ b/lisp/net/browse-url.el
@@ -1,6 +1,6 @@
;;; browse-url.el --- pass a URL to a WWW browser
-;; Copyright (C) 1995, 96, 97, 98, 99, 2000, 2001, 2004
+;; Copyright (C) 1995, 96, 97, 98, 99, 2000, 2001, 2004, 2005
;; Free Software Foundation, Inc.
;; Author: Denis Howe <[email protected]>
@@ -387,6 +387,14 @@ If non-nil, then open the URL in a new tab rather than a new window if
:type 'boolean
:group 'browse-url)
+(defcustom browse-url-netscape-new-window-is-tab nil
+ "*Whether to open up new windows in a tab or a new window.
+If non-nil, then open the URL in a new tab rather than a new
+window if `browse-url-netscape' is asked to open it in a new
+window."
+ :type 'boolean
+ :group 'browse-url)
+
(defcustom browse-url-new-window-flag nil
"*If non-nil, always open a new browser window with appropriate browsers.
Passing an interactive argument to \\[browse-url], or specific browser
@@ -834,6 +842,10 @@ non-nil, load the document in a new Netscape window, otherwise use a
random existing one. A non-nil interactive prefix argument reverses
the effect of `browse-url-new-window-flag'.
+If `browse-url-netscape-new-window-is-tab' is non-nil, then
+whenever a document would otherwise be loaded in a new window, it
+is loaded in a new tab in an existing window instead.
+
When called non-interactively, optional second argument NEW-WINDOW is
used instead of `browse-url-new-window-flag'."
(interactive (browse-url-interactive-arg "URL: "))
@@ -843,21 +855,24 @@ used instead of `browse-url-new-window-flag'."
(setq url (replace-match
(format "%%%x" (string-to-char (match-string 0 url))) t t url)))
(let* ((process-environment (browse-url-process-environment))
- (process (apply 'start-process
- (concat "netscape " url) nil
- browse-url-netscape-program
- (append
- browse-url-netscape-arguments
- (if (eq window-system 'w32)
- (list url)
- (append
- (if new-window '("-noraise"))
- (list "-remote"
- (concat "openURL(" url
- (if (browse-url-maybe-new-window
- new-window)
- ",new-window")
- ")"))))))))
+ (process
+ (apply 'start-process
+ (concat "netscape " url) nil
+ browse-url-netscape-program
+ (append
+ browse-url-netscape-arguments
+ (if (eq window-system 'w32)
+ (list url)
+ (append
+ (if new-window '("-noraise"))
+ (list "-remote"
+ (concat "openURL(" url
+ (if (browse-url-maybe-new-window
+ new-window)
+ (if browse-url-netscape-new-window-is-tab
+ ",new-tab"
+ ",new-window"))
+ ")"))))))))
(set-process-sentinel process
`(lambda (process change)
(browse-url-netscape-sentinel process ,url)))))
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el
index 583b5fa2af..0fee809789 100644
--- a/lisp/net/tramp.el
+++ b/lisp/net/tramp.el
@@ -4105,7 +4105,7 @@ ARGS are the arguments OPERATION has been called with."
(if (bufferp (nth 0 args)) (nth 0 args) (current-buffer))))
; COMMAND
((member operation
- (list 'dired-call-process-command
+ (list 'dired-call-process
; Emacs only
'shell
; Post Emacs 21.3 only
diff --git a/lisp/pcvs.el b/lisp/pcvs.el
index cd0cf0a2df..2c0016dcc4 100644
--- a/lisp/pcvs.el
+++ b/lisp/pcvs.el
@@ -1,7 +1,7 @@
;;; pcvs.el --- a front-end to CVS
;; Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-;; 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
+;; 2000, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
;; Author: (The PCL-CVS Trust) [email protected]
;; (Per Cederqvist) [email protected]
@@ -1687,8 +1687,7 @@ Signal an error if there is no backup file."
(message "Retrieving revision %s..." rev)
;; Discard stderr output to work around the CVS+SSH+libc
;; problem when stdout and stderr are the same.
- ;; FIXME: this doesn't seem to make any difference :-(
- (let ((res (apply 'call-process cvs-program nil '(t . nil) nil
+ (let ((res (apply 'call-process cvs-program nil '(t nil) nil
"-q" "update" "-p"
;; If `rev' is HEAD, don't pass it at all:
;; the default behavior is to get the head
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el
index 4eeb8fa188..3c1251ba59 100644
--- a/lisp/progmodes/gdb-ui.el
+++ b/lisp/progmodes/gdb-ui.el
@@ -338,7 +338,6 @@ detailed description of this mode.
(match-string 3)
nil nil)))
(push var gdb-var-list)
- (setq speedbar-update-flag t)
(speedbar 1)
(if (equal (nth 2 var) "0")
(gdb-enqueue-input
@@ -433,7 +432,18 @@ detailed description of this mode.
`(lambda () (gdb-var-evaluate-expression-handler
,varnum t)))))))
(setq gdb-pending-triggers
- (delq 'gdb-var-update gdb-pending-triggers)))
+ (delq 'gdb-var-update gdb-pending-triggers))
+ (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame))
+ ;; dummy command to update speedbar at right time
+ (gdb-enqueue-input (list "server pwd\n" 'gdb-speedbar-timer-fn))
+ ;; keep gdb-pending-triggers non-nil till end
+ (push 'gdb-speedbar-timer gdb-pending-triggers)))
+
+(defun gdb-speedbar-timer-fn ()
+ (setq gdb-pending-triggers
+ (delq 'gdb-speedbar-timer gdb-pending-triggers))
+ (with-current-buffer gud-comint-buffer
+ (speedbar-timer-fn)))
(defun gdb-var-delete ()
"Delete watched expression from the speedbar."
@@ -882,12 +892,12 @@ happens to be appropriate."
(gdb-invalidate-threads)
(unless (eq system-type 'darwin) ;Breaks on Darwin's GDB-5.3.
;; FIXME: with GDB-6 on Darwin, this might very well work.
- (dolist (frame (frame-list))
- (when (string-equal (frame-parameter frame 'name) "Speedbar")
- (setq gdb-var-changed t) ; force update
- (dolist (var gdb-var-list)
- (setcar (nthcdr 5 var) nil))))
- (gdb-var-update))))
+ ;; only needed/used with speedbar/watch expressions
+ (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame))
+ (setq gdb-var-changed t) ; force update
+ (dolist (var gdb-var-list)
+ (setcar (nthcdr 5 var) nil))
+ (gdb-var-update)))))
(let ((sink gdb-output-sink))
(cond
((eq sink 'user) t)
diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el
index aabc2f5783..da6b6f772b 100644
--- a/lisp/progmodes/hideif.el
+++ b/lisp/progmodes/hideif.el
@@ -958,7 +958,10 @@ Return as (TOP . BOTTOM) the extent of ifdef block."
(defun hide-ifdef-use-define-alist (name)
"Set `hide-ifdef-env' to the define list specified by NAME."
- (interactive "SUse define list: ")
+ (interactive
+ (list (completing-read "Use define list: "
+ hide-ifdef-define-alist nil t)))
+ (if (stringp name) (setq name (intern name)))
(let ((define-list (assoc name hide-ifdef-define-alist)))
(if define-list
(setq hide-ifdef-env
diff --git a/lisp/progmodes/meta-mode.el b/lisp/progmodes/meta-mode.el
index ecf8da2e50..7bf9921b2e 100644
--- a/lisp/progmodes/meta-mode.el
+++ b/lisp/progmodes/meta-mode.el
@@ -898,7 +898,7 @@ The environment marked is the one that contains point or follows point."
;; Compatibility: XEmacs doesn't have the `mark-active' variable.
(defun meta-mark-active ()
"Return whether the mark and region are currently active in this buffer."
- (or (and (boundp 'mark-active) mark-active) (mark)))
+ (if (boundp 'mark-active) mark-active (mark)))
diff --git a/lisp/progmodes/scheme.el b/lisp/progmodes/scheme.el
index bf0f18d5bb..d9ffea852d 100644
--- a/lisp/progmodes/scheme.el
+++ b/lisp/progmodes/scheme.el
@@ -330,6 +330,10 @@ See `run-hooks'."
"map" "syntax" "syntax-rules") t)
"\\>") 1)
;;
+ ;; It wouldn't be Scheme w/o named-let.
+ '("(let\\s-+\\(\\sw+\\)"
+ (1 font-lock-function-name-face))
+ ;;
;; David Fox <[email protected]> for SOS/STklos class specifiers.
'("\\<<\\sw+>\\>" . font-lock-type-face)
;;
diff --git a/lisp/ps-print.el b/lisp/ps-print.el
index 24c05745b7..330a09de41 100644
--- a/lisp/ps-print.el
+++ b/lisp/ps-print.el
@@ -986,7 +986,7 @@ Please send all bug fixes and enhancements to
;; (my-mixed-family
;; (fonts (normal . "Courier-Bold")
;; (bold . "Helvetica")
-;; (italic . "Zapf-Chancery-MediumItalic")
+;; (italic . "ZapfChancery-MediumItalic")
;; (bold-italic . "NewCenturySchlbk-BoldItalic")
;; (w3-table-hack-x-face . "LineDrawNormal"))
;; (size . 10.0)
@@ -1010,7 +1010,7 @@ Please send all bug fixes and enhancements to
;; (fonts (w3-table-hack-x-face . "LineDrawNormal")
;; (bold . "Helvetica")
;; (bold-italic . "NewCenturySchlbk-BoldItalic")
-;; (italic . "Zapf-Chancery-MediumItalic")
+;; (italic . "ZapfChancery-MediumItalic")
;; (normal . "Courier-Bold"))
;; (avg-char-width . 6.0)
;; (space-width . 6.0)
@@ -2820,8 +2820,16 @@ It has effect only when `ps-spool-duplex' is non-nil."
(line-height . 9.63)
(space-width . 2.78)
(avg-char-width . 2.78))
+ (ZapfChancery-MediumItalic
+ (fonts (normal . "ZapfChancery-MediumItalic"))
+ (size . 10.0)
+ (line-height . 11.45)
+ (space-width . 2.2)
+ (avg-char-width . 4.10811))
+ ;; We keep this wrong entry name (but with correct font name) for
+ ;; backward compatibility.
(Zapf-Chancery-MediumItalic
- (fonts (normal . "Zapf-Chancery-MediumItalic"))
+ (fonts (normal . "ZapfChancery-MediumItalic"))
(size . 10.0)
(line-height . 11.45)
(space-width . 2.2)
diff --git a/lisp/replace.el b/lisp/replace.el
index de3577913c..2c60cd006f 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -115,8 +115,11 @@ wants to replace FROM with TO."
query-replace-from-history-variable
nil t t))))
(if (and (zerop (length from)) lastto lastfrom)
- (cons lastfrom
- (query-replace-compile-replacement lastto regexp-flag))
+ (progn
+ (cons lastfrom
+ (query-replace-compile-replacement lastto regexp-flag))
+ (set query-replace-from-history-variable
+ (cdr (symbol-value query-replace-from-history-variable))))
;; Warn if user types \n or \t, but don't reject the input.
(and regexp-flag
(string-match "\\(\\`\\|[^\\]\\)\\(\\\\\\\\\\)*\\(\\\\[nt]\\)" from)
@@ -214,7 +217,11 @@ Fourth and fifth arg START and END specify the region to operate on.
To customize possible responses, change the \"bindings\" in `query-replace-map'."
(interactive (let ((common
- (query-replace-read-args "Query replace" nil)))
+ (query-replace-read-args
+ (if (and transient-mark-mode mark-active)
+ "Query replace in region"
+ "Query replace")
+ nil)))
(list (nth 0 common) (nth 1 common) (nth 2 common)
;; These are done separately here
;; so that command-history will record these expressions
@@ -274,7 +281,11 @@ text, TO-STRING is actually made a list instead of a string.
Use \\[repeat-complex-command] after this command for details."
(interactive
(let ((common
- (query-replace-read-args "Query replace regexp" t)))
+ (query-replace-read-args
+ (if (and transient-mark-mode mark-active)
+ "Query replace regexp in region"
+ "Query replace regexp")
+ t)))
(list (nth 0 common) (nth 1 common) (nth 2 common)
;; These are done separately here
;; so that command-history will record these expressions
@@ -420,7 +431,11 @@ which will run faster and will not set the mark or print anything.
and TO-STRING is also null.)"
(interactive
(let ((common
- (query-replace-read-args "Replace string" nil)))
+ (query-replace-read-args
+ (if (and transient-mark-mode mark-active)
+ "Replace string in region"
+ "Replace string")
+ nil)))
(list (nth 0 common) (nth 1 common) (nth 2 common)
(if (and transient-mark-mode mark-active)
(region-beginning))
@@ -474,7 +489,11 @@ What you probably want is a loop like this:
which will run faster and will not set the mark or print anything."
(interactive
(let ((common
- (query-replace-read-args "Replace regexp" t)))
+ (query-replace-read-args
+ (if (and transient-mark-mode mark-active)
+ "Replace regexp in region"
+ "Replace regexp")
+ t)))
(list (nth 0 common) (nth 1 common) (nth 2 common)
(if (and transient-mark-mode mark-active)
(region-beginning))
diff --git a/lisp/ses.el b/lisp/ses.el
index c2239327e1..502acf868d 100644
--- a/lisp/ses.el
+++ b/lisp/ses.el
@@ -1281,34 +1281,20 @@ to each symbol."
;; This should be unnecessary, because the feature is now built in.
-;;; (defadvice undo-more (around ses-undo-more activate preactivate)
-;;; "Define a meaning for conses in buffer-undo-list whose car is a symbol
-;;; other than t or nil. To undo these, apply the car--a function--to the
-;;; cdr--its arglist."
-;;; (let ((ses-count (ad-get-arg 0)))
-;;; (catch 'undo
-;;; (dolist (ses-x pending-undo-list)
-;;; (unless ses-x
-;;; ;;End of undo boundary
-;;; (setq ses-count (1- ses-count))
-;;; (if (<= ses-count 0)
-;;; ;;We've seen enough boundaries - stop undoing
-;;; (throw 'undo nil)))
-;;; (and (consp ses-x) (symbolp (car ses-x)) (fboundp (car ses-x))
-;;; ;;Undo using apply
-;;; (apply (car ses-x) (cdr ses-x)))))
-;;; (if (not (eq major-mode 'ses-mode))
-;;; ad-do-it
-;;; ;;Here is some extra code for SES mode.
-;;; (setq ses--deferred-narrow
-;;; (or ses--deferred-narrow (ses-narrowed-p)))
-;;; (widen)
-;;; (condition-case x
-;;; ad-do-it
-;;; (error
-;;; ;;Restore narrow if appropriate
-;;; (ses-command-hook)
-;;; (signal (car x) (cdr x)))))))
+(defadvice undo-more (around ses-undo-more activate preactivate)
+ "For SES mode, allow undo outside of narrowed buffer range."
+ (if (not (eq major-mode 'ses-mode))
+ ad-do-it
+ ;;Here is some extra code for SES mode.
+ (setq ses--deferred-narrow
+ (or ses--deferred-narrow (ses-narrowed-p)))
+ (widen)
+ (condition-case x
+ ad-do-it
+ (error
+ ;;Restore narrow if appropriate
+ (ses-command-hook)
+ (signal (car x) (cdr x))))))
(defun ses-begin-change ()
"For undo, remember point before we start changing hidden stuff."
diff --git a/lisp/simple.el b/lisp/simple.el
index 25168baa9e..e63adffa62 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -3158,12 +3158,12 @@ and more reliable (no dependence on goal column, etc.)."
(let ((abbrev-mode nil))
(end-of-line)
(insert "\n"))
- (line-move arg))
+ (line-move arg nil nil t))
(if (interactive-p)
(condition-case nil
- (line-move arg)
+ (line-move arg nil nil t)
((beginning-of-buffer end-of-buffer) (ding)))
- (line-move arg)))
+ (line-move arg nil nil t)))
nil)
(defun previous-line (&optional arg)
@@ -3186,9 +3186,9 @@ to use and more reliable (no dependence on goal column, etc.)."
(or arg (setq arg 1))
(if (interactive-p)
(condition-case nil
- (line-move (- arg))
+ (line-move (- arg) nil nil t)
((beginning-of-buffer end-of-buffer) (ding)))
- (line-move (- arg)))
+ (line-move (- arg) nil nil t))
nil)
(defcustom track-eol nil
@@ -3227,8 +3227,8 @@ Outline mode sets this."
(assq prop buffer-invisibility-spec)))))
;; Perform vertical scrolling of tall images if necessary.
-(defun line-move (arg &optional noerror to-end)
- (if auto-window-vscroll
+(defun line-move (arg &optional noerror to-end try-vscroll)
+ (if (and auto-window-vscroll try-vscroll)
(let ((forward (> arg 0))
(part (nth 2 (pos-visible-in-window-p (point) nil t))))
(if (and (consp part)
@@ -3244,7 +3244,14 @@ Outline mode sets this."
(* (frame-char-height) (- arg))))))
t)
(set-window-vscroll nil 0)
- (line-move-1 arg noerror to-end)))
+ (when (line-move-1 arg noerror to-end)
+ (sit-for 0)
+ (if (and (not forward)
+ (setq part (nth 2 (pos-visible-in-window-p
+ (line-beginning-position) nil t)))
+ (> (cdr part) 0))
+ (set-window-vscroll nil (cdr part) t))
+ t)))
(line-move-1 arg noerror to-end)))
;; This is the guts of next-line and previous-line.
diff --git a/lisp/subr.el b/lisp/subr.el
index 0c3515cb73..10094409ad 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -2221,10 +2221,10 @@ and replace a sub-expression, e.g.
(defun subregexp-context-p (regexp pos &optional start)
"Return non-nil if POS is in a normal subregexp context in REGEXP.
A subregexp context is one where a sub-regexp can appear.
-A non-subregexp context is for example within brackets, or within a repetition
-bounds operator \\{..\\}, or right after a \\.
-If START is non-nil, it should be a position in REGEXP, smaller than POS,
-and known to be in a subregexp context."
+A non-subregexp context is for example within brackets, or within a
+repetition bounds operator `\\=\\{...\\}', or right after a `\\'.
+If START is non-nil, it should be a position in REGEXP, smaller
+than POS, and known to be in a subregexp context."
;; Here's one possible implementation, with the great benefit that it
;; reuses the regexp-matcher's own parser, so it understands all the
;; details of the syntax. A disadvantage is that it needs to match the
diff --git a/lisp/term/mac-win.el b/lisp/term/mac-win.el
index 8835015161..53c4f55bd5 100644
--- a/lisp/term/mac-win.el
+++ b/lisp/term/mac-win.el
@@ -1,6 +1,7 @@
;;; mac-win.el --- parse switches controlling interface with Mac window system
-;; Copyright (C) 1999, 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
+;; Copyright (C) 1999, 2000, 2002, 2003, 2004, 2005
+;; Free Software Foundation, Inc.
;; Author: Andrew Choi <[email protected]>
;; Keywords: terminals
@@ -1013,16 +1014,16 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
(define-key function-key-map [M-return] [?\M-\C-m])
(define-key function-key-map [tab] [?\t])
(define-key function-key-map [M-tab] [?\M-\t])
-(define-key function-key-map [backspace] [127])
+(define-key function-key-map [backspace] [?\d])
(define-key function-key-map [M-backspace] [?\M-\d])
(define-key function-key-map [escape] [?\e])
(define-key function-key-map [M-escape] [?\M-\e])
;; These tell read-char how to convert
;; these special chars to ASCII.
-(put 'return 'ascii-character 13)
+(put 'return 'ascii-character ?\C-m)
(put 'tab 'ascii-character ?\t)
-(put 'backspace 'ascii-character 127)
+(put 'backspace 'ascii-character ?\d)
(put 'escape 'ascii-character ?\e)
@@ -1268,7 +1269,7 @@ Switch to a buffer editing the last file dropped."
(unless (eq system-type 'darwin)
;; This variable specifies the Unix program to call (as a process) to
- ;; deteremine the amount of free space on a file system (defaults to
+ ;; determine the amount of free space on a file system (defaults to
;; df). If it is not set to nil, ls-lisp will not work correctly
;; unless an external application df is implemented on the Mac.
(setq directory-free-space-program nil)
@@ -1276,20 +1277,17 @@ Switch to a buffer editing the last file dropped."
;; Set this so that Emacs calls subprocesses with "sh" as shell to
;; expand filenames Note no subprocess for the shell is actually
;; started (see run_mac_command in sysdep.c).
- (setq shell-file-name "sh"))
+ (setq shell-file-name "sh")
+
+ ;; To display filenames in Chinese or Japanese, replace mac-roman with
+ ;; big5 or sjis
+ (setq file-name-coding-system 'mac-roman))
;; X Window emulation in macterm.c is not complete enough to start a
;; frame without a minibuffer properly. Call this to tell ediff
;; library to use a single frame.
; (ediff-toggle-multiframe)
-(if (eq system-type 'darwin)
- ;; On Darwin filenames are encoded in UTF-8
- (setq file-name-coding-system 'utf-8)
- ;; To display filenames in Chinese or Japanese, replace mac-roman with
- ;; big5 or sjis
- (setq file-name-coding-system 'mac-roman))
-
;; If Emacs is started from the Finder, change the default directory
;; to the user's home directory.
(if (string= default-directory "/")
@@ -1307,5 +1305,5 @@ Switch to a buffer editing the last file dropped."
;; (prefer-coding-system 'mac-roman)
-;;; arch-tag: 71dfcd14-cde8-4d66-b05c-85ec94fb23a6
+;; arch-tag: 71dfcd14-cde8-4d66-b05c-85ec94fb23a6
;;; mac-win.el ends here
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el
index c3b0f561cc..1c6fb17f79 100644
--- a/lisp/textmodes/ispell.el
+++ b/lisp/textmodes/ispell.el
@@ -671,6 +671,12 @@ regular expression \"[']\" for OTHERCHARS. Then \"they're\" and
If you want OTHERCHARS to be empty, use the empty string.
Hint: regexp syntax requires the hyphen to be declared first here.
+CASECHAS, NOT-CASECHARS, and OTHERCHARS must be a unibyte string
+containing bytes of CHARACTER-SET. In addition, if they contain
+a non-ASCII byte, the regular expression must be a single
+`character set' construct that doesn't specify a character range
+for non-ASCII bytes.
+
MANY-OTHERCHARS-P is non-nil when multiple OTHERCHARS are allowed in a word.
Otherwise only a single OTHERCHARS character is allowed to be part of any
single word.
diff --git a/lisp/tooltip.el b/lisp/tooltip.el
index 2e60df0245..c4ac57eac9 100644
--- a/lisp/tooltip.el
+++ b/lisp/tooltip.el
@@ -488,7 +488,7 @@ MSG is either a help string to display, or nil to cancel the display."
(setq pos (posn-at-x-y (car pos) (cdr pos) (car mp)))
(windowp (posn-window pos)))
(with-current-buffer (window-buffer (posn-window pos))
- (if (mouse-on-link-p (posn-point pos))
+ (if (mouse-on-link-p pos)
(setq msg (concat
(cond
((eq mouse-1-click-follows-link 'double) "double-")
diff --git a/lisp/wdired.el b/lisp/wdired.el
index 928ecd6533..92d7a81627 100644
--- a/lisp/wdired.el
+++ b/lisp/wdired.el
@@ -3,7 +3,7 @@
;; Copyright (C) 2001, 2004 Free Software Foundation, Inc.
;; Filename: wdired.el
-;; Author: Juan León Lahoz García <[email protected]>
+;; Author: Juan Le�n Lahoz Garc�a <[email protected]>
;; Version: 1.91
;; Keywords: dired, environment, files, renaming