Merged in changes from CVS trunk.

Patches applied:

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-616
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-617
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-618
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-619
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-620
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-621
   Merge from gnus--rel--5.10

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-622
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-623
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-624
   Update from CVS

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-625
   Update from CVS

 * miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-51
   Update from CVS

 * miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-52
   Update from CVS

 * miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-53
   Merge from emacs--cvs-trunk--0


git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-261
This commit is contained in:
Karoly Lorentey 2004-10-19 17:00:02 +00:00
commit 90b404757b
70 changed files with 1181 additions and 1830 deletions

File diff suppressed because it is too large Load diff

View file

@ -1,12 +1,19 @@
% Reference Card for GNU Emacs version 21 on Unix systems
%**start of header
\newcount\columnsperpage
\newcount\letterpaper
% This file can be printed with 1, 2, or 3 columns per page (see below).
% Specify how many you want here. Nothing else needs to be changed.
% Specify how many you want here.
\columnsperpage=1
\columnsperpage=3
% Set letterpapaer to 0 for A4 paper, 1 for letter (US) paper. Useful
% only when columnsperpage is 2 or 3.
\letterpaper=1
% Nothing else needs to be changed below this line.
% Copyright (c) 1987, 1993, 1996, 1997 Free Software Foundation, Inc.
% This file is part of GNU Emacs.
@ -42,6 +49,10 @@
% For this you need a dvi device driver that can print sideways.
% Which mode to use is controlled by setting \columnsperpage above.
%
% To compile and print this document:
% tex refcard.tex
% dvips -t landscape refcard.dvi
%
% Author:
% Stephen Gildea
% Internet: gildea@stop.mail-abuse.org
@ -103,7 +114,11 @@
\def\makefootline{\baselineskip10pt\hsize6.5in\line{\the\footline}}
\else %2 or 3 columns uses prereduced size
\hsize 3.2in
\vsize 7.95in
\if 1\the\letterpaper
\vsize 7.95in
\else
\vsize 7.65in
\fi
\hoffset -.75in
\voffset -.745in
\font\titlefont=cmbx10 \scaledmag2
@ -123,7 +138,11 @@
\def\bf{\eightbf}
\def\it{\eightit}
\def\tt{\eighttt}
\normalbaselineskip=.8\normalbaselineskip
\if 1\the\letterpaper
\normalbaselineskip=.8\normalbaselineskip
\else
\normalbaselineskip=.7\normalbaselineskip
\fi
\normallineskip=.8\normallineskip
\normallineskiplimit=.8\normallineskiplimit
\normalbaselines\rm %make definitions take effect

View file

@ -1,10 +1,164 @@
2004-10-18 David Ponce <david@dponce.com>
* mouse.el (mouse-drag-move-window-top): New function.
(mouse-drag-mode-line-1): Use it.
2004-10-18 Thien-Thi Nguyen <ttn@gnu.org>
* info.el (Info-fontify-node): For multiline refs,
arrange to unfontify newline and surrounding whitespace.
2004-10-17 Stefan Monnier <monnier@iro.umontreal.ca>
* vc-arch.el (vc-arch-workfile-version): Don't burp if the patch-log
directory is missing.
2004-10-17 John Paul Wallington <jpw@gnu.org>
* ibuffer.el (ibuffer-default-display-maybe-show-predicates):
New customizable variable; whether to display buffers that match
`ibuffer-maybe-show-predicates' by default.
(ibuffer-maybe-show-predicates): Mention it in docstring.
(ibuffer-display-maybe-show-predicates): New variable.
(ibuffer-update): Prefix arg now toggles whether buffers that
match `ibuffer-maybe-show-predicates' should be displayed.
(ibuffer-mode): Set `ibuffer-display-maybe-show-predicates'
locally to heed `ibuffer-default-display-maybe-show-predicates'.
(ibuffer-redisplay-engine): Rename optional second arg to `ignore'.
2004-10-17 Michael Albinus <michael.albinus@gmx.de>
* net/tramp.el: Redo sync with Tramp 2.0.45. Last commit did not
work correctly.
2004-10-17 Daniel Pfeiffer <occitan@esperanto.org>
* buff-menu.el (Buffer-menu-revert-function): Emulate save-excursion.
(Buffer-menu-beginning): New helper function.
(Buffer-menu-execute): Use it.
(Buffer-menu-select): Use it.
(Buffer-menu-sort): Use it and also keep markers.
2004-10-17 Richard M. Stallman <rms@gnu.org>
* paths.el (news-directory): Rename from news-path. Old name alias.
(rmail-spool-directory): Use defvar.
(sendmail-program): Use defcustom.
(remote-shell-program): Use defcustom.
(term-file-prefix): Use defvar.
(abbrev-file-name): Use defvar.
* term.el: Add maintainer.
* subr.el (with-local-quit): Return nil if there's a quit.
(read-passwd): Use with-local-quit. Doc fix.
* strokes.el (strokes-list-strokes): Don't try to delete char at eob.
(strokes-unload-hook): Set as a variable with add-hook.
* startup.el (fancy-splash-tail, normal-splash-screen):
Update copyright year.
* shadowfile.el (shadowfile-unload-hook): Set as variable w/ add-hook.
* server.el (server-unload-hook): Set as a variable with add-hook.
* help-at-pt.el (help-at-pt-unload-hook): Use add-hook; no defvar.
* frame.el (special-display-popup-frame):
Make the buffer current as its frame is created.
* delsel.el (delsel-unload-hook): Set as a variable.
* comint.el (comint-output-filter-functions):
Add comint-watch-for-password-prompt.
(comint-read-noecho): Function deleted.
(send-invisible): Use read-passwd.
* fringe.el (fringe-mode-initialize): New function.
(fringe-mode): Use fringe-mode-initialize as :initialize.
2004-10-17 Kim F. Storm <storm@cua.dk>
* language/indian.el (indian-script-language-alist): Swap value and doc.
(indian-font-char-index-table): Doc fix.
2004-10-16 Stefan Monnier <monnier@iro.umontreal.ca>
* vc-hooks.el (vc-find-file-hook): Call vc-backend with absolute name.
2004-10-16 Juri Linkov <juri@jurta.org>
* progmodes/compile.el (compilation-start): Move let-binding of
`process-environment' into `with-current-buffer' body.
Reported by Matt Hodges <MPHodges@member.fsf.org>.
2004-10-16 Richard M. Stallman <rms@gnu.org>
* pcvs-util.el (cvs-bury-buffer):
Don't call get-buffer-window for effect.
* outline.el (hide-other): Call outline-up-heading with INVISIBLE-OK=t.
* newcomment.el (comment-auto-fill-only-comments): Add autoload.
* msb.el (msb-unload-hook): Set the variable.
* mouse.el (mouse-yank-at-click, mouse-yank-secondary):
Use * to err if buffer is readonly.
* subr.el (looking-back): Return only t or nil.
* whitespace.el (whitespace-unload-hook): Set the variable.
* view.el (view-mode-enable): Set view-page-size and
view-half-page-size to nil.
(view-set-half-page-size-default): view-half-page-size = nil
means the default.
(View-scroll-page-forward): Use view-page-size-default.
(View-scroll-page-backward): Likewise.
(view-page-size, view-half-page-size): Doc fixes.
* emacs-lisp/elp.el (elp-unload-hook): Set the variable.
* emacs-lisp/cl.el (cl-unload-hook): Don't defvar it, just set it.
* emacs-lisp/bytecomp.el (byte-compile-eval): Don't process
"cl" like other files. Instead, call byte-compile-find-cl-functions.
(byte-compile-log-1): Bind inhibit-read-only.
(byte-compile-warning-prefix, byte-compile-log-file): Likewise.
(byte-compile-log-warning): Likewise.
(byte-compile-file-form-require): Detect "cl" from the arg value.
* progmodes/compile.el (compilation-start): Assume compilation-mode
will make the buffer read-only.
(compilation-mode): Take arg name-of-mode.
(compilation-setup): Make buffer read-only.
(compilation-handle-exit): Bind inhibit-read-only.
* textmodes/ispell.el (ispell-command-loop): Use with-no-warnings.
(ispell-message): Likewise.
(ispell-show-choices): Don't call get-buffer-window uselessly.
(ispell-init-process): Use set-process-query-on-exit-flag.
2004-10-16 Kim F. Storm <storm@cua.dk>
* fringe.el (fringe-bitmaps): Only initialize when defined.
* pcvs.el (cvs-mode-view-file, cvs-mode-view-file-other-window): Add.
(cvs-mode-find-file): Add optional `view' arg to enter view mode.
* pcvs-defs.el (cvs-mode-map): Bind v to cvs-mode-view-file.
2004-10-15 Simon Josefsson <jas@extundo.com>
* net/password.el: Add.
2004-10-13 Daniel Pfeiffer <occitan@esperanto.org>
* button.el (button-activate): Allow a marker to display as an
action.
* button.el (button-activate): Allow a marker to display as an action.
* help-fns.el (describe-variable): Use it to make "below" a
hyperlink.
* help-fns.el (describe-variable): Use it to make "below" a hyperlink.
* help.el (describe-mode): Use it to make minor mode list into
hyperlinks.
@ -25,6 +179,15 @@
(event-modifiers): Use push.
(mouse-movement-p, with-temp-buffer): Simplify.
2004-10-12 Richard M. Stallman <rms@gnu.org>
* info-look.el (info-lookup-file): Add info-file property.
(info-lookup-symbol): Likewise.
* info.el (info-xref): Add underlining.
(info): Add info-file property.
(Info-find-emacs-command-nodes): Specify case-sensitive search.
2004-10-12 Michael Albinus <michael.albinus@gmx.de>
Sync with Tramp 2.0.45.
@ -201,7 +364,7 @@
2004-10-05 Juri Linkov <juri@jurta.org>
* isearch.el (isearch-done): Set mark after running hook.
Suggested by Drew Adams <drew.adams@oracle.com>.
Reported by Drew Adams <drew.adams@oracle.com>.
* info.el (Info-history, Info-toc): Fix Info headers.
(Info-toc): Narrow buffer before Info-fontify-node.

View file

@ -197,9 +197,15 @@ Letters do not insert themselves; instead, they are commands.
(defun Buffer-menu-revert-function (ignore1 ignore2)
;; We can not use save-excursion here. The buffer gets erased.
(let ((old-point (point)))
(let ((ocol (current-column))
(oline (progn (move-to-column 4)
(get-text-property (point) 'buffer)))
(prop (point-min)))
(list-buffers-noselect Buffer-menu-files-only)
(goto-char old-point)))
(while (setq prop (next-single-property-change prop 'buffer))
(when (eq (get-text-property prop 'buffer) oline)
(goto-char prop)
(move-to-column ocol)))))
(defun Buffer-menu-toggle-files-only (arg)
"Toggle whether the current buffer-menu displays only file buffers.
@ -354,13 +360,16 @@ and then move up one line. Prefix arg means move that many lines."
(delete-char 1)
(insert (if arg ?* ? ))))))
(defun Buffer-menu-beginning ()
(goto-char (point-min))
(unless Buffer-menu-use-header-line
(forward-line)))
(defun Buffer-menu-execute ()
"Save and/or delete buffers marked with \\<Buffer-menu-mode-map>\\[Buffer-menu-save] or \\<Buffer-menu-mode-map>\\[Buffer-menu-delete] commands."
(interactive)
(save-excursion
(goto-char (point-min))
(unless Buffer-menu-use-header-line
(forward-line 1))
(Buffer-menu-beginning)
(while (re-search-forward "^..S" nil t)
(let ((modp nil))
(save-excursion
@ -371,9 +380,7 @@ and then move up one line. Prefix arg means move that many lines."
(delete-char -1)
(insert (if modp ?* ? ))))))
(save-excursion
(goto-char (point-min))
(unless Buffer-menu-use-header-line
(forward-line 1))
(Buffer-menu-beginning)
(let ((buff-menu-buffer (current-buffer))
(buffer-read-only nil))
(while (re-search-forward "^D" nil t)
@ -399,9 +406,7 @@ in the selected frame."
(menu (current-buffer))
(others ())
tem)
(goto-char (point-min))
(unless Buffer-menu-use-header-line
(forward-line 1))
(Buffer-menu-beginning)
(while (re-search-forward "^>" nil t)
(setq tem (Buffer-menu-buffer t))
(let ((buffer-read-only nil))
@ -581,7 +586,35 @@ For more information, see the function `buffer-menu'."
(if (< column 2) (setq column 2))
(if (> column 5) (setq column 5)))
(setq Buffer-menu-sort-column column)
(Buffer-menu-revert))
(let (buffer-read-only l buf m1 m2)
(save-excursion
(Buffer-menu-beginning)
(while (not (eobp))
(when (buffer-live-p (setq buf (get-text-property (+ (point) 4) 'buffer)))
(setq m1 (char-after)
m1 (if (memq m1 '(?> ?D)) m1)
m2 (char-after (+ (point) 2))
m2 (if (eq m2 ?S) m2))
(if (or m1 m2)
(push (list buf m1 m2) l)))
(forward-line)))
(Buffer-menu-revert)
(setq buffer-read-only)
(save-excursion
(Buffer-menu-beginning)
(while (not (eobp))
(when (setq buf (assq (get-text-property (+ (point) 4) 'buffer) l))
(setq m1 (cadr buf)
m2 (cadr (cdr buf)))
(when m1
(delete-char 1)
(insert m1)
(backward-char 1))
(when m2
(forward-char 2)
(delete-char 1)
(insert m2)))
(forward-line)))))
(defun Buffer-menu-make-sort-button (name column)
(if (equal column Buffer-menu-sort-column) (setq column nil))
@ -592,7 +625,9 @@ For more information, see the function `buffer-menu'."
'mouse-face 'highlight
'keymap (let ((map (make-sparse-keymap)))
(define-key map [header-line mouse-2]
`(lambda () (interactive)
`(lambda (e)
(interactive "e")
(if e (set-buffer (window-buffer (posn-window (event-end e)))))
(Buffer-menu-sort ,column)))
map)))

View file

@ -112,34 +112,27 @@ C-w Describe how there is no warranty for Calc."
(describe-bindings)
(save-excursion
(set-buffer "*Help*")
(goto-char (point-min))
(if (search-forward "Global bindings:" nil t)
(delete-region (match-beginning 0) (point-max)))
(goto-char (point-min))
(while (re-search-forward "\n[a-z] ESC" nil t)
(end-of-line)
(delete-region (match-beginning 0) (point)))
(goto-char (point-min))
(while (re-search-forward "\nESC m" nil t)
(end-of-line)
(delete-region (match-beginning 0) (point)))
(goto-char (point-min))
(while (search-forward "\n\n\n" nil t)
(backward-delete-char 1)
(backward-char 2))
(goto-char (point-min))
(while
(re-search-forward
"\n[a-z] [0-9]\\(\t\t.*\n\\)\\([a-z] [0-9]\\1\\)*[a-z] \\([0-9]\\)\\1"
nil t)
(let ((dig1 (char-after (1- (match-beginning 1))))
(dig2 (char-after (match-beginning 3))))
(delete-region (match-end 1) (match-end 0))
(goto-char (match-beginning 1))
(delete-backward-char 1)
(delete-char 1)
(insert (format "%c .. %c" (min dig1 dig2) (max dig1 dig2)))))
(goto-char (point-min))))
(let ((buffer-read-only nil))
(goto-char (point-min))
(when (search-forward "Major Mode Bindings:" nil t)
(delete-region (point-min) (point))
(insert "Calc Mode Bindings:"))
(when (search-forward "Global bindings:" nil t)
(forward-line -1)
(delete-region (point) (point-max)))
(goto-char (point-min))
(while
(re-search-forward
"\n[a-z] [0-9]\\( .*\n\\)\\([a-z] [0-9]\\1\\)*[a-z] \\([0-9]\\)\\1"
nil t)
(let ((dig1 (char-after (1- (match-beginning 1))))
(dig2 (char-after (match-beginning 3))))
(delete-region (match-end 1) (match-end 0))
(goto-char (match-beginning 1))
(delete-backward-char 1)
(delete-char 5)
(insert (format "%c .. %c" (min dig1 dig2) (max dig1 dig2)))))
(goto-char (point-min)))))
(defun calc-describe-key-briefly (key)
(interactive "kDescribe key briefly: ")

View file

@ -372,7 +372,7 @@ history list. Default is to save anything that isn't all whitespace.")
"Special hook run before input is sent to the process.
These functions get one argument, a string containing the text to send.")
(defvar comint-output-filter-functions '(comint-postoutput-scroll-to-bottom)
(defvar comint-output-filter-functions '(comint-postoutput-scroll-to-bottom comint-watch-for-password-prompt)
"Functions to call after output is inserted into the buffer.
One possible function is `comint-postoutput-scroll-to-bottom'.
These functions get one argument, a string containing the text as originally
@ -1901,65 +1901,7 @@ prompt skip is done by skipping text matching the regular expression
;; These three functions are for entering text you don't want echoed or
;; saved -- typically passwords to ftp, telnet, or somesuch.
;; Just enter m-x send-invisible and type in your line, or add
;; `comint-watch-for-password-prompt' to `comint-output-filter-functions'.
(defun comint-read-noecho (prompt &optional stars)
"Read a single line of text from user without echoing, and return it.
Prompt with argument PROMPT, a string. Optional argument STARS causes
input to be echoed with '*' characters on the prompt line. Input ends with
RET, LFD, or ESC. DEL or C-h rubs out. C-u kills line. C-g aborts (if
`inhibit-quit' is set because e.g. this function was called from a process
filter and C-g is pressed, this function returns nil rather than a string).
Note that the keystrokes comprising the text can still be recovered
\(temporarily) with \\[view-lossage]. Some people find this worrisome (see,
however, `clear-this-command-keys').
Once the caller uses the password, it can erase the password
by doing (clear-string STRING)."
(let ((ans "")
(newans nil)
(c 0)
(echo-keystrokes 0)
(cursor-in-echo-area t)
(message-log-max nil)
(done nil))
(while (not done)
(if stars
(message "%s%s" prompt (make-string (length ans) ?*))
(message "%s" prompt))
;; Use this instead of `read-char' to avoid "Non-character input-event".
(setq c (read-char-exclusive))
(cond ((= c ?\C-g)
;; This function may get called from a process filter, where
;; inhibit-quit is set. In later versions of emacs read-char
;; may clear quit-flag itself and return C-g. That would make
;; it impossible to quit this loop in a simple way, so
;; re-enable it here (for backward-compatibility the check for
;; quit-flag below would still be necessary, so this seems
;; like the simplest way to do things).
(setq quit-flag t
done t))
((or (= c ?\r) (= c ?\n) (= c ?\e))
(setq done t))
((= c ?\C-u)
(clear-string ans)
(setq ans ""))
((and (/= c ?\b) (/= c ?\177))
(setq newans (concat ans (char-to-string c)))
(clear-string ans)
(setq ans newans))
((> (length ans) 0)
(aset ans (1- (length ans)) 0)
(setq ans (substring ans 0 -1)))))
(if quit-flag
;; Emulate a true quit, except that we have to return a value.
(prog1
(setq quit-flag nil)
(message "Quit")
(beep t))
(message "")
ans)))
;; Just enter m-x send-invisible and type in your line.
(defun send-invisible (&optional prompt)
"Read a string without echoing.
@ -1970,7 +1912,7 @@ Security bug: your string can still be temporarily recovered with
(interactive "P") ; Defeat snooping via C-x ESC ESC
(let ((proc (get-buffer-process (current-buffer))))
(if proc
(let ((str (comint-read-noecho (or prompt "Non-echoed text: ") t)))
(let ((str (read-passwd (or prompt "Non-echoed text: "))))
(if (stringp str)
(progn
(comint-snapshot-last-prompt)

View file

@ -147,6 +147,8 @@ then it takes a second \\[keyboard-quit] to abort the minibuffer."
(define-key minibuffer-local-must-match-map "\C-g" 'abort-recursive-edit)
(define-key minibuffer-local-isearch-map "\C-g" 'abort-recursive-edit))
(add-hook 'delsel-unload-hook 'delsel-unload-hook)
(provide 'delsel)
;;; arch-tag: 1e388890-1b50-4ed0-9347-763b1343b6ed

View file

@ -792,7 +792,8 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
(let ((xs (pop hist-new))
old-autoloads)
;; Make sure the file was not already loaded before.
(unless (assoc (car xs) hist-orig)
(unless (or (assoc (car xs) hist-orig)
(equal (car xs) "cl"))
(dolist (s xs)
(cond
((symbolp s)
@ -809,7 +810,18 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
(when (and (symbolp s) (not (memq s old-autoloads)))
(push s byte-compile-noruntime-functions))
(when (and (consp s) (eq t (car s)))
(push (cdr s) old-autoloads))))))))))
(push (cdr s) old-autoloads)))))))
(when (memq 'cl-functions byte-compile-warnings)
(let ((hist-new load-history)
(hist-nil-new current-load-list))
;; Go through load-history, look for newly loaded files
;; and mark all the functions defined therein.
(while (and hist-new (not (eq hist-new hist-orig)))
(let ((xs (pop hist-new))
old-autoloads)
;; Make sure the file was not already loaded before.
(when (and (equal (car xs) "cl") (not (assoc (car xs) hist-orig)))
(byte-compile-find-cl-functions)))))))))
(defun byte-compile-eval-before-compile (form)
"Evaluate FORM for `eval-and-compile'."
@ -848,12 +860,13 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
;; Log something that isn't a warning.
(defun byte-compile-log-1 (string)
(with-current-buffer "*Compile-Log*"
(goto-char (point-max))
(byte-compile-warning-prefix nil nil)
(cond (noninteractive
(message " %s" string))
(t
(insert (format "%s\n" string))))))
(let ((inhibit-read-only t))
(goto-char (point-max))
(byte-compile-warning-prefix nil nil)
(cond (noninteractive
(message " %s" string))
(t
(insert (format "%s\n" string)))))))
(defvar byte-compile-read-position nil
"Character position we began the last `read' from.")
@ -904,7 +917,8 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
;; This is used as warning-prefix for the compiler.
;; It is always called with the warnings buffer current.
(defun byte-compile-warning-prefix (level entry)
(let* ((dir default-directory)
(let* ((inhibit-read-only t)
(dir default-directory)
(file (cond ((stringp byte-compile-current-file)
(format "%s:" (file-relative-name byte-compile-current-file dir)))
((bufferp byte-compile-current-file)
@ -950,7 +964,8 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
(save-excursion
(set-buffer (get-buffer-create "*Compile-Log*"))
(goto-char (point-max))
(let* ((dir (and byte-compile-current-file
(let* ((inhibit-read-only t)
(dir (and byte-compile-current-file
(file-name-directory byte-compile-current-file)))
(was-same (equal default-directory dir))
pt)
@ -984,7 +999,8 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
(defun byte-compile-log-warning (string &optional fill level)
(let ((warning-prefix-function 'byte-compile-warning-prefix)
(warning-type-format "")
(warning-fill-prefix (if fill " ")))
(warning-fill-prefix (if fill " "))
(inhibit-read-only t))
(display-warning 'bytecomp string level "*Compile-Log*")))
(defun byte-compile-warn (format &rest args)
@ -2140,17 +2156,15 @@ list that represents a doc string reference.
(setq tail (cdr tail))))
form)
(put 'require 'byte-hunk-handler 'byte-compile-file-form-eval-boundary)
(defun byte-compile-file-form-eval-boundary (form)
(let ((old-load-list current-load-list))
(eval form)
;; (require 'cl) turns off warnings for cl functions.
(let ((tem current-load-list))
(while (not (eq tem old-load-list))
(when (equal (car tem) '(require . cl))
(setq byte-compile-warnings
(remq 'cl-functions byte-compile-warnings)))
(setq tem (cdr tem)))))
(put 'require 'byte-hunk-handler 'byte-compile-file-form-require)
(defun byte-compile-file-form-require (form)
(let ((old-load-list current-load-list)
(args (mapcar 'eval (cdr form))))
(apply 'require args)
;; Detech (require 'cl) in a way that works even if cl is already loaded.
(if (member (car args) '("cl" cl))
(setq byte-compile-warnings
(remq 'cl-functions byte-compile-warnings))))
(byte-compile-keep-pending form 'byte-compile-normal-call))
(put 'progn 'byte-hunk-handler 'byte-compile-file-form-progn)

View file

@ -108,8 +108,7 @@ printer proceeds to the next function on the list.
This variable is not used at present, but it is defined in hopes that
a future Emacs interpreter will be able to use it.")
(defvar cl-unload-hook '(cl-cannot-unload)
"Prevent unloading the feature `cl', since it does not work.")
(add-hook 'cl-unload-hook 'cl-cannot-unload)
(defun cl-cannot-unload ()
(error "Cannot unload the feature `cl'"))

View file

@ -626,6 +626,7 @@ displayed."
(defun elp-unload-hook ()
(elp-restore-all))
(add-hook 'elp-unload-hook 'elp-unload-hook)
(provide 'elp)

View file

@ -153,7 +153,9 @@ Pass it BUFFER as first arg, and (cdr ARGS) gives the rest of the args."
;; (set-window-dedicated-p window t)
window))
;; If no window yet, make one in a new frame.
(let ((frame (make-frame (append args special-display-frame-alist))))
(let ((frame
(with-current-buffer buffer
(make-frame (append args special-display-frame-alist)))))
(set-window-buffer (frame-selected-window frame) buffer)
(set-window-dedicated-p (frame-selected-window frame) t)
(frame-selected-window frame))))))

View file

@ -43,7 +43,8 @@
(defvar fringe-bitmaps)
(unless (get 'left-truncation 'fringe)
(unless (or (not (boundp 'fringe-bitmaps))
(get 'left-truncation 'fringe))
(let ((bitmaps '(left-truncation right-truncation
up-arrow down-arrow
continued-line continuation-line
@ -112,6 +113,25 @@ See `fringe-mode' for possible values and their effect."
fringe-mode))))
(setq frames (cdr frames)))))
;; For initialization of fringe-mode, take account of changes
;; made explicitly to default-frame-alist.
(defun fringe-mode-initialize (symbol value)
(let* ((left-pair (assq 'left-fringe default-frame-alist))
(right-pair (assq 'right-fringe default-frame-alist))
(left (cdr left-pair))
(right (cdr right-pair)))
(if (or left-pair right-pair)
;; If there's something in default-frame-alist for fringes,
;; don't change it, but reflect that into the value of fringe-mode.
(progn
(setq fringe-mode (cons left right))
(if (equal fringe-mode '(nil . nil))
(setq fringe-mode nil))
(if (equal fringe-mode '(0 . 0))
(setq fringe-mode 0)))
;; Otherwise impose the user-specified value of fringe-mode.
(custom-initialize-reset symbol value))))
;;;###autoload
(defcustom fringe-mode nil
"*Specify appearance of fringes on all frames.
@ -138,6 +158,7 @@ you can use the interactive function `toggle-fringe'"
(integer :tag "Right width")))
:group 'frames
:require 'fringe
:initialize 'fringe-mode-initialize
:set 'set-fringe-mode-1)
(defun fringe-query-style (&optional all-frames)

View file

@ -1,3 +1,33 @@
2004-10-17 Richard M. Stallman <rms@gnu.org>
* gnus-registry.el (gnus-registry-unload-hook):
Set as a variable with add-hook.
* nnspool.el (nnspool-spool-directory): Use news-directory instead
of news-path.
* spam-stat.el (spam-stat-unload-hook): Set as a variable w/ add-hook.
* spam.el: Delete duplicate `provide'.
(spam-unload-hook): Set as a variable with add-hook.
2004-10-15 Reiner Steib <Reiner.Steib@gmx.de>
* pop3.el (pop3-leave-mail-on-server): Describe possible problems
in the doc string.
* message.el (message-ignored-news-headers)
(message-ignored-supersedes-headers)
(message-ignored-resent-headers)
(message-forward-ignored-headers): Improve custom type.
2004-10-15 Simon Josefsson <jas@extundo.com>
* pop3.el (top-level): Don't require nnheader.
(pop3-read-timeout): Add.
(pop3-accept-process-output): Add.
(pop3-read-response, pop3-retr): Use it.
2004-10-13 Katsumi Yamaoka <yamaoka@jpl.org>
* message.el (message-tokenize-header): Fix 2004-09-06 change
@ -9,6 +39,10 @@
(tls-certificate-information): New function, based on
ssl-certificate-information.
2004-10-11 Reiner Steib <Reiner.Steib@gmx.de>
* message.el (message-bury): Use `window-dedicated-p'.
2004-10-10 Reiner Steib <Reiner.Steib@gmx.de>
* gnus-sum.el: Mention that multibyte characters don't work as marks.

View file

@ -693,6 +693,8 @@ Returns the first place where the trail finds a group name."
(remove-hook 'gnus-summary-prepare-hook 'gnus-registry-register-message-ids))
(add-hook 'gnus-registry-unload-hook 'gnus-registry-unload-hook)
(when gnus-registry-install
(gnus-registry-install-hooks)
(gnus-registry-read))

View file

@ -255,7 +255,12 @@ included. Organization and User-Agent are optional."
:group 'message-news
:group 'message-headers
:link '(custom-manual "(message)Message Headers")
:type 'regexp)
:type '(repeat :value-to-internal (lambda (widget value)
(custom-split-regexp-maybe value))
:match (lambda (widget value)
(or (stringp value)
(widget-editable-list-match widget value)))
regexp))
(defcustom message-ignored-mail-headers
"^[GF]cc:\\|^Resent-Fcc:\\|^Xref:\\|^X-Draft-From:\\|^X-Gnus-Agent-Meta-Information:"
@ -271,7 +276,12 @@ It's best to delete old Path and Date headers before posting to avoid
any confusion."
:group 'message-interface
:link '(custom-manual "(message)Superseding")
:type 'regexp)
:type '(repeat :value-to-internal (lambda (widget value)
(custom-split-regexp-maybe value))
:match (lambda (widget value)
(or (stringp value)
(widget-editable-list-match widget value)))
regexp))
(defcustom message-subject-re-regexp
"^[ \t]*\\([Rr][Ee]\\(\\[[0-9]*\\]\\)*:[ \t]*\\)*[ \t]*"
@ -534,13 +544,22 @@ Done before generating the new subject of a forward."
"*All headers that match this regexp will be deleted when resending a message."
:group 'message-interface
:link '(custom-manual "(message)Resending")
:type 'regexp)
:type '(repeat :value-to-internal (lambda (widget value)
(custom-split-regexp-maybe value))
:match (lambda (widget value)
(or (stringp value)
(widget-editable-list-match widget value)))
regexp))
(defcustom message-forward-ignored-headers "^Content-Transfer-Encoding:\\|^X-Gnus"
"*All headers that match this regexp will be deleted when forwarding a message."
:version "21.1"
:group 'message-forwarding
:type '(choice (const :tag "None" nil)
:type '(repeat :value-to-internal (lambda (widget value)
(custom-split-regexp-maybe value))
:match (lambda (widget value)
(or (stringp value)
(widget-editable-list-match widget value)))
regexp))
(defcustom message-ignored-cited-headers "."

View file

@ -44,7 +44,7 @@ This is most commonly `inews' or `injnews'.")
"Switches for nnspool-request-post to pass to `inews' for posting news.
If you are using Cnews, you probably should set this variable to nil.")
(defvoo nnspool-spool-directory (file-name-as-directory news-path)
(defvoo nnspool-spool-directory (file-name-as-directory news-directory)
"Local news spool directory.")
(defvoo nnspool-nov-directory (concat nnspool-spool-directory "over.view/")

View file

@ -83,7 +83,14 @@ values are 'apop."
:group 'pop3)
(defcustom pop3-leave-mail-on-server nil
"*Non-nil if the mail is to be left on the POP server after fetching."
"*Non-nil if the mail is to be left on the POP server after fetching.
If the `pop3-leave-mail-on-server' is non-`nil' the mail is to be
left on the POP server after fetching. Note that POP servers
maintain no state information between sessions, so what the
client believes is there and what is actually there may not match
up. If they do not, then the whole thing can fall apart and
leave you with a corrupt mailbox."
:version "21.4" ;; Oort Gnus
:type 'boolean
:group 'pop3)
@ -95,6 +102,32 @@ Used for APOP authentication.")
(defvar pop3-read-point nil)
(defvar pop3-debug nil)
;; Borrowed from nnheader-accept-process-output in nnheader.el.
(defvar pop3-read-timeout
(if (string-match "windows-nt\\|os/2\\|emx\\|cygwin"
(symbol-name system-type))
;; http://thread.gmane.org/v9655t3pjo.fsf@marauder.physik.uni-ulm.de
;;
;; IIRC, values lower than 1.0 didn't/don't work on Windows/DOS.
;;
;; There should probably be a runtime test to determine the timing
;; resolution, or a primitive to report it. I don't know off-hand
;; what's possible. Perhaps better, maybe the Windows/DOS primitive
;; could round up non-zero timeouts to a minimum of 1.0?
1.0
0.1)
"How long pop3 should wait between checking for the end of output.
Shorter values mean quicker response, but are more CPU intensive.")
;; Borrowed from nnheader-accept-process-output in nnheader.el.
(defun pop3-accept-process-output (process)
(accept-process-output
process
(truncate pop3-read-timeout)
(truncate (* (- pop3-read-timeout
(truncate pop3-read-timeout))
1000))))
(defun pop3-movemail (&optional crashbox)
"Transfer contents of a maildrop to the specified CRASHBOX."
(or crashbox (setq crashbox (expand-file-name "~/.crashbox")))
@ -207,7 +240,7 @@ Return the response string if optional second argument is non-nil."
(goto-char pop3-read-point)
(while (and (memq (process-status process) '(open run))
(not (search-forward "\r\n" nil t)))
(nnheader-accept-process-output process)
(pop3-accept-process-output process)
(goto-char pop3-read-point))
(setq match-end (point))
(goto-char pop3-read-point)
@ -381,8 +414,7 @@ This function currently does nothing.")
(save-excursion
(set-buffer (process-buffer process))
(while (not (re-search-forward "^\\.\r\n" nil t))
;; Fixme: Shouldn't depend on nnheader.
(nnheader-accept-process-output process)
(pop3-accept-process-output process)
(goto-char start))
(setq pop3-read-point (point-marker))
;; this code does not seem to work for some POP servers...

View file

@ -594,6 +594,8 @@ COUNT defaults to 5"
(remove-hook 'gnus-select-article-hook
'spam-stat-store-gnus-article-buffer))
(add-hook 'spam-stat-unload-hook 'spam-stat-unload-hook)
(provide 'spam-stat)
;;; arch-tag: ff1d2200-8ddb-42fb-bb7b-1b5e20448554

View file

@ -1814,14 +1814,12 @@ REMOVE not nil, remove the ADDRESSES."
(remove-hook 'gnus-get-new-news-hook 'spam-setup-widening)
(remove-hook 'gnus-summary-prepare-hook 'spam-find-spam))
(add-hook 'spam-unload-hook 'spam-unload-hook)
(when spam-install-hooks
(spam-initialize))
(provide 'spam)
;;; spam.el ends here.
(provide 'spam)
;;; arch-tag: 07e6e0ca-ab0a-4412-b445-1f6c72a4f27f
;;; spam.el ends here

View file

@ -348,8 +348,7 @@ different regions. With numeric argument ARG, behaves like
(interactive "p")
(scan-buf-move-to-region 'help-echo (- arg) 'scan-buf-move-hook))
(defvar help-at-pt-unload-hook '(help-at-pt-cancel-timer)
"Normal hook run when `help-at-pt' is unloaded.")
(add-hook 'help-at-pt-unload-hook 'help-at-pt-cancel-timer)
(provide 'help-at-pt)

View file

@ -213,12 +213,20 @@ If a regexp, then it will be matched against the buffer's name.
If a function, it will be called with the buffer as an argument, and
should return non-nil if this buffer should be shown.
Viewing of buffers hidden because of these predicates is enabled by
giving a non-nil prefix argument to `ibuffer-update'. Note that this
specialized filtering occurs before real filtering."
Viewing of buffers hidden because of these predicates may be customized
via `ibuffer-default-display-maybe-show-predicates' and is toggled by
giving a non-nil prefix argument to `ibuffer-update'.
Note that this specialized filtering occurs before real filtering."
:type '(repeat (choice regexp function))
:group 'ibuffer)
(defcustom ibuffer-default-display-maybe-show-predicates nil
"Non-nil means show buffers that match `ibuffer-maybe-show-predicates'."
:type 'boolean
:group 'ibuffer)
(defvar ibuffer-display-maybe-show-predicates nil)
(defvar ibuffer-current-format nil)
(defcustom ibuffer-movement-cycle t
@ -2069,11 +2077,15 @@ If optional arg SILENT is non-nil, do not display progress messages."
(defun ibuffer-update (arg &optional silent)
"Regenerate the list of all buffers.
Display buffers whose name matches one of `ibuffer-maybe-show-predicates'
iff arg ARG is non-nil.
Prefix arg non-nil means to toggle whether buffers that match
`ibuffer-maybe-show-predicates' should be displayed.
If optional arg SILENT is non-nil, do not display progress messages."
(interactive "P")
(if arg
(setq ibuffer-display-maybe-show-predicates
(not ibuffer-display-maybe-show-predicates)))
(ibuffer-forward-line 0)
(let* ((bufs (buffer-list))
(blist (ibuffer-filter-buffers
@ -2086,7 +2098,7 @@ If optional arg SILENT is non-nil, do not display progress messages."
(caddr bufs)
(cadr bufs))
(ibuffer-current-buffers-with-marks bufs)
arg)))
ibuffer-display-maybe-show-predicates)))
(when (null blist)
(if (and (featurep 'ibuf-ext)
ibuffer-filtering-qualifiers)
@ -2148,7 +2160,7 @@ If optional arg SILENT is non-nil, do not display progress messages."
'ibuffer-filter-group
name)))
(defun ibuffer-redisplay-engine (bmarklist &optional all)
(defun ibuffer-redisplay-engine (bmarklist &optional ignore)
(assert (eq major-mode 'ibuffer-mode))
(let* ((--ibuffer-insert-buffers-and-marks-format
(ibuffer-current-format))
@ -2475,6 +2487,8 @@ will be inserted before the group at point."
ibuffer-default-sorting-reversep)
(set (make-local-variable 'ibuffer-shrink-to-minimum-size)
ibuffer-default-shrink-to-minimum-size)
(set (make-local-variable 'ibuffer-display-maybe-show-predicates)
ibuffer-default-display-maybe-show-predicates)
(set (make-local-variable 'ibuffer-filtering-qualifiers) nil)
(set (make-local-variable 'ibuffer-filter-groups) nil)
(set (make-local-variable 'ibuffer-filter-group-kill-ring) nil)

View file

@ -3445,7 +3445,8 @@ Preserve text properties."
(fontify-visited-p ; visited nodes need to be re-fontified
(and Info-fontify-visited-nodes
;; Don't take time to refontify visited nodes in huge nodes
(< (- (point-max) (point-min)) Info-fontify-maximum-menu-size))))
(< (- (point-max) (point-min)) Info-fontify-maximum-menu-size)))
rbeg rend)
;; Fontify header line
(goto-char (point-min))
@ -3570,39 +3571,48 @@ Preserve text properties."
"mouse-2: go to this node")
'mouse-face 'highlight)))
(when (or not-fontified-p fontify-visited-p)
(add-text-properties
(match-beginning 2) (match-end 2)
(list
'font-lock-face
;; Display visited nodes in a different face
(if (and Info-fontify-visited-nodes
(save-match-data
(let* ((node (replace-regexp-in-string
"^[ \t]+" ""
(replace-regexp-in-string
"[ \t\n]+" " "
(or (match-string 5)
(and (not (equal (match-string 4) ""))
(match-string 4))
(match-string 2)))))
(file (file-name-nondirectory
Info-current-file))
(hl Info-history-list)
res)
(if (string-match "(\\([^)]+\\))\\([^)]*\\)" node)
(setq file (file-name-nondirectory
(match-string 1 node))
node (if (equal (match-string 2 node) "")
"Top"
(match-string 2 node))))
(while hl
(if (and (string-equal node (nth 1 (car hl)))
(string-equal file
(file-name-nondirectory
(nth 0 (car hl)))))
(setq res (car hl) hl nil)
(setq hl (cdr hl))))
res))) 'info-xref-visited 'info-xref))))
(setq rbeg (match-beginning 2)
rend (match-end 2))
(put-text-property
rbeg rend
'font-lock-face
;; Display visited nodes in a different face
(if (and Info-fontify-visited-nodes
(save-match-data
(let* ((node (replace-regexp-in-string
"^[ \t]+" ""
(replace-regexp-in-string
"[ \t\n]+" " "
(or (match-string 5)
(and (not (equal (match-string 4) ""))
(match-string 4))
(match-string 2)))))
(file (file-name-nondirectory
Info-current-file))
(hl Info-history-list)
res)
(if (string-match "(\\([^)]+\\))\\([^)]*\\)" node)
(setq file (file-name-nondirectory
(match-string 1 node))
node (if (equal (match-string 2 node) "")
"Top"
(match-string 2 node))))
(while hl
(if (and (string-equal node (nth 1 (car hl)))
(string-equal file
(file-name-nondirectory
(nth 0 (car hl)))))
(setq res (car hl) hl nil)
(setq hl (cdr hl))))
res))) 'info-xref-visited 'info-xref))
;; For multiline ref, unfontify newline and surrounding whitespace
(save-excursion
(goto-char rbeg)
(save-match-data
(while (re-search-forward "\\s-*\n\\s-*" rend t nil)
(remove-text-properties (match-beginning 0)
(match-end 0)
'(font-lock-face t))))))
(when not-fontified-p
(when (memq Info-hide-note-references '(t hide))
(add-text-properties (match-beginning 3) (match-end 3)

View file

@ -50,6 +50,15 @@
Currently supported foundries are `cdac' and `akruti'.")
(defvar indian-script-language-alist
'((devanagari (hindi sanskrit) nil)
(bengali (bengali assamese) nil)
(gurmukhi (punjabi) nil)
(gujarati (gujarati) nil)
(oriya (oriya) nil)
(tamil (tamil) nil)
(telugu (telugu) nil)
(kannada (kannada) nil)
(malayalam (malayalam) nil))
"Alist of Indian scripts vs the corresponding language list and font foundry.
Each element has this form:
@ -62,16 +71,7 @@ The list is in the priority order.
FONT-FOUNDRY is a font foundry representing a group of Indian
fonts. If the value is nil, the value of `indian-font-foundry'
is used."
'((devanagari (hindi sanskrit) nil)
(bengali (bengali assamese) nil)
(gurmukhi (punjabi) nil)
(gujarati (gujarati) nil)
(oriya (oriya) nil)
(tamil (tamil) nil)
(telugu (telugu) nil)
(kannada (kannada) nil)
(malayalam (malayalam) nil)))
is used.")
(defconst indian-font-char-index-table
'( ; for which language(s)
@ -99,14 +99,14 @@ is used."
(#x1200 . akruti:knd) ; kannada
(#x1300 . akruti:mal) ; malayalam
)
"Aliat of indices of `indian-glyph' character vs Indian font identifiers.
"Alist of indices of `indian-glyph' character vs Indian font identifiers.
Each element has this form: (INDEX . FONT-IDENTIFIER)
INDEX is an index number of the first character in the charset
`indian-glyph' assigned for glyphs in the font specified by
FONT-IDENTIFIER. Currently FONT-IDENTIFIERs are defined for CDAC
and AKRUTI font groups.")
(defun indian-font-char (index font-identifier)
"Return character of charset `indian-glyph' made from glyph index INDEX.
FONT-IDENTIFIER is an identifier of an Indian font listed in the
@ -127,7 +127,7 @@ font INDEX is for."
(defun indian-font-char-range (font-identifier)
(cons (indian-font-char 0 font-identifier)
(indian-font-char 255 font-identifier)))
(defvar indian-script-table
'[
devanagari

View file

@ -338,6 +338,17 @@ shrink the window or windows above it to make room."
(select-window window)
(enlarge-window growth nil (> growth 0))))
(defsubst mouse-drag-move-window-top (window growth)
"Move the top of WINDOW up or down by GROWTH lines.
Move it down if GROWTH is positive, or up if GROWTH is negative.
If this would make WINDOW too short, shrink the window or windows
above it to make room."
;; Moving the top of WINDOW is actually moving the bottom of the
;; window above.
(let ((window-above (mouse-drag-window-above window)))
(and window-above
(mouse-drag-move-window-bottom window-above (- growth)))))
(defun mouse-drag-mode-line-1 (start-event mode-line-p)
"Change the height of a window by dragging on the mode or header line.
START-EVENT is the starting mouse-event of the drag action.
@ -444,7 +455,9 @@ MODE-LINE-P non-nil means dragging a mode line; nil means a header line."
(select-window start-event-window))
;; no. grow/shrink the selected window
;(message "growth = %d" growth)
(mouse-drag-move-window-bottom start-event-window growth))
(if mode-line-p
(mouse-drag-move-window-bottom start-event-window growth)
(mouse-drag-move-window-top start-event-window growth)))
;; if this window's growth caused another
;; window to be deleted because it was too
@ -1097,7 +1110,7 @@ and set mark at the beginning.
Prefix arguments are interpreted as with \\[yank].
If `mouse-yank-at-point' is non-nil, insert at point
regardless of where you click."
(interactive "e\nP")
(interactive "*e\nP")
;; Give temporary modes such as isearch a chance to turn off.
(run-hooks 'mouse-leave-buffer-hook)
(or mouse-yank-at-point (mouse-set-point click))
@ -1399,7 +1412,7 @@ The function returns a non-nil value if it creates a secondary selection."
Move point to the end of the inserted text.
If `mouse-yank-at-point' is non-nil, insert at point
regardless of where you click."
(interactive "e")
(interactive "*e")
;; Give temporary modes such as isearch a chance to turn off.
(run-hooks 'mouse-leave-buffer-hook)
(or mouse-yank-at-point (mouse-set-point click))

View file

@ -1153,6 +1153,7 @@ different buffer menu using the function `msb'."
(defun msb-unload-hook ()
(msb-mode 0))
(add-hook 'msb-unload-hook 'msb-unload-hook)
(provide 'msb)
(eval-after-load "msb" '(run-hooks 'msb-after-load-hook 'msb-after-load-hooks))

128
lisp/net/password.el Normal file
View file

@ -0,0 +1,128 @@
;;; password.el --- Read passwords from user, possibly using a password cache.
;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc.
;; Author: Simon Josefsson <simon@josefsson.org>
;; Created: 2003-12-21
;; Keywords: password cache passphrase key
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING. If not, write to the
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Greatly influenced by pgg.el written by Daiki Ueno, with timer
;; fixes for XEmacs by Katsumi Yamaoka. In fact, this is mostly just
;; a rip-off.
;;
;; (password-read "Password? " "test")
;; ;; Minibuffer prompt for password.
;; => "foo"
;;
;; (password-cache-add "test" "foo")
;; => nil
;; Note the previous two can be replaced with:
;; (password-read-and-add "Password? " "test")
;; ;; Minibuffer prompt for password.
;; => "foo"
;; ;; "foo" is now cached with key "test"
;; (password-read "Password? " "test")
;; ;; No minibuffer prompt
;; => "foo"
;;
;; (password-read "Password? " "test")
;; ;; No minibuffer prompt
;; => "foo"
;;
;; ;; Wait `password-cache-expiry' seconds.
;;
;; (password-read "Password? " "test")
;; ;; Minibuffer prompt for password is back.
;; => "foo"
;;; Code:
(when (featurep 'xemacs)
(require 'run-at-time))
(eval-when-compile
(require 'cl))
(defcustom password-cache t
"Whether to cache passwords."
:group 'password
:type 'boolean)
(defcustom password-cache-expiry 16
"How many seconds passwords are cached, or nil to disable expiring.
Whether passwords are cached at all is controlled by `password-cache'."
:group 'password
:type '(choice (const :tag "Never" nil)
(integer :tag "Seconds")))
(defvar password-data (make-vector 7 0))
(defun password-read (prompt &optional key)
"Read password, for use with KEY, from user, or from cache if wanted.
KEY indicate the purpose of the password, so the cache can
separate passwords. The cache is not used if KEY is nil. It is
typically a string.
The variable `password-cache' control whether the cache is used."
(or (and password-cache
key
(symbol-value (intern-soft key password-data)))
(read-passwd prompt)))
(defun password-read-and-add (prompt &optional key)
"Read password, for use with KEY, from user, or from cache if wanted.
Then store the password in the cache. Uses `password-read' and
`password-cache-add'."
(let ((password (password-read prompt key)))
(when (and password key)
(password-cache-add key password))
password))
(defun password-cache-remove (key)
"Remove password indexed by KEY from password cache.
This is typically run be a timer setup from `password-cache-add',
but can be invoked at any time to forcefully remove passwords
from the cache. This may be useful when it has been detected
that a password is invalid, so that `password-read' query the
user again."
(let ((password (symbol-value (intern-soft key password-data))))
(when password
(fillarray password ?_)
(unintern key password-data))))
(defun password-cache-add (key password)
"Add password to cache.
The password is removed by a timer after `password-cache-expiry'
seconds."
(set (intern key password-data) password)
(when password-cache-expiry
(run-at-time password-cache-expiry nil
#'password-cache-remove
key))
nil)
(provide 'password)
;;; arch-tag: ab160494-16c8-4c68-a4a1-73eebf6686e5
;;; password.el ends here

View file

@ -2337,45 +2337,46 @@ If it doesn't exist, generate a new one."
;; This function makes the same assumption as
;; `tramp-handle-set-visited-file-modtime'.
(defun tramp-handle-verify-visited-file-modtime (buf)
"Like `verify-visited-file-modtime' for tramp files.
At the time `verify-visited-file-modtime' calls this function, we
already know that the buffer is visiting a file and that
`visited-file-modtime' does not return 0. Do not call this
function directly, unless those two cases are already taken care
of."
"Like `verify-visited-file-modtime' for tramp files."
(with-current-buffer buf
(let ((f (buffer-file-name)))
(with-parsed-tramp-file-name f nil
(let* ((attr (file-attributes f))
(modtime (nth 5 attr)))
(cond ((and attr (not (equal modtime '(0 0))))
;; Why does `file-attributes' return a list (HIGH
;; LOW), but `visited-file-modtime' returns a cons
;; (HIGH . LOW)?
(let ((mt (visited-file-modtime)))
(< (abs (tramp-time-diff
modtime
;; For compatibility, deal with both the old
;; (HIGH . LOW) and the new (HIGH LOW)
;; return values of `visited-file-modtime'.
(if (atom (cdr mt))
(list (car mt) (cdr mt))
mt)))
2)))
(attr
(save-excursion
(tramp-send-command
multi-method method user host
(format "%s -ild %s"
(tramp-get-ls-command multi-method method
user host)
(tramp-shell-quote-argument localname)))
(tramp-wait-for-output)
(setq attr (buffer-substring
(point) (progn (end-of-line) (point)))))
(equal tramp-buffer-file-attributes attr))
;; If file does not exist, say it is not modified.
(t nil)))))))
;; There is no file visiting the buffer, or the buffer has no
;; recorded last modification time.
(if (or (not (buffer-file-name))
(eq (visited-file-modtime) 0))
t
(let ((f (buffer-file-name)))
(with-parsed-tramp-file-name f nil
(let* ((attr (file-attributes f))
(modtime (nth 5 attr))
(mt (visited-file-modtime)))
(cond
;; file exists, and has a known modtime.
((and attr (not (equal modtime '(0 0))))
(< (abs (tramp-time-diff
modtime
;; For compatibility, deal with both the old
;; (HIGH . LOW) and the new (HIGH LOW)
;; return values of `visited-file-modtime'.
(if (atom (cdr mt))
(list (car mt) (cdr mt))
mt)))
2))
;; modtime has the don't know value.
(attr
(save-excursion
(tramp-send-command
multi-method method user host
(format "%s -ild %s"
(tramp-get-ls-command multi-method method user host)
(tramp-shell-quote-argument localname)))
(tramp-wait-for-output)
(setq attr (buffer-substring
(point) (progn (end-of-line) (point)))))
(equal tramp-buffer-file-attributes attr))
;; If file does not exist, say it is not modified
;; if and only if that agrees with the buffer's record.
(t (equal mt '(-1 65535))))))))))
(defadvice clear-visited-file-modtime (after tramp activate)
"Set `tramp-buffer-file-attributes' back to nil.

View file

@ -1087,6 +1087,7 @@ Else, call `comment-indent'."
(insert (comment-padleft comment-end add)))
(indent-according-to-mode))))))
;;;###autoload
(defcustom comment-auto-fill-only-comments nil
"Non-nil means to only auto-fill inside comments.
This has no effect in modes that do not define a comment syntax."

View file

@ -808,7 +808,7 @@ Show the heading too, if it is currently invisible."
(save-excursion
(outline-back-to-heading t)
(show-entry)
(while (condition-case nil (progn (outline-up-heading 1) (not (bobp)))
(while (condition-case nil (progn (outline-up-heading 1 t) (not (bobp)))
(error nil))
(outline-flag-region (1- (point))
(save-excursion (forward-line 1) (point))

View file

@ -101,11 +101,12 @@ This variable `Info-default-directory-list' is used as the default
for initializing `Info-directory-list' when Info is started, unless
the environment variable INFOPATH is set.")
(defvar news-path
(defvar news-directory
(if (file-exists-p "/usr/spool/news/")
"/usr/spool/news/"
"/var/spool/news/")
"The root directory below which all news files are stored.")
(defalias 'news-path 'news-directory)
(defvar news-inews-program
(cond ((file-exists-p "/usr/bin/inews") "/usr/bin/inews")
@ -136,7 +137,7 @@ The `ORGANIZATION' environment variable is used instead if defined.")
:group 'rmail
:version "21.1")
(defconst rmail-spool-directory
(defvar rmail-spool-directory
(cond ((string-match "^[^-]+-[^-]+-sco3.2v4" system-configuration)
"/usr/spool/mail/")
;; On The Bull DPX/2 /usr/spool/mail is used although
@ -157,15 +158,17 @@ The `ORGANIZATION' environment variable is used instead if defined.")
"Name of directory used by system mailer for delivering new mail.
Its name should end with a slash.")
(defconst sendmail-program
(defcustom sendmail-program
(cond
((file-exists-p "/usr/sbin/sendmail") "/usr/sbin/sendmail")
((file-exists-p "/usr/lib/sendmail") "/usr/lib/sendmail")
((file-exists-p "/usr/ucblib/sendmail") "/usr/ucblib/sendmail")
(t "fakemail")) ;In ../etc, to interface to /bin/mail.
"Program used to send messages.")
"Program used to send messages."
:group 'mail
:type 'file)
(defconst remote-shell-program
(defcustom remote-shell-program
(cond
;; Some systems use rsh for the remote shell; others use that name for the
;; restricted shell and use remsh for the remote shell. Let's try to guess
@ -186,14 +189,16 @@ Its name should end with a slash.")
((file-exists-p "/bin/rsh") "/bin/rsh")
((file-exists-p "/usr/bin/rsh") "/usr/bin/rsh")
(t "rsh"))
"File name for remote-shell program (often rsh or remsh).")
"File name for remote-shell program (often rsh or remsh)."
:group 'environment
:type 'file)
(defconst term-file-prefix (if (eq system-type 'vax-vms) "[.term]" "term/") "\
(defvar term-file-prefix (if (eq system-type 'vax-vms) "[.term]" "term/") "\
If non-nil, Emacs startup does (load (concat term-file-prefix (getenv \"TERM\")))
You may set this variable to nil in your `.emacs' file if you do not wish
the terminal-initialization file to be loaded.")
(defconst abbrev-file-name
(defvar abbrev-file-name
(if (eq system-type 'vax-vms)
"~/abbrev.def"
(convert-standard-filename "~/.abbrev_defs"))

View file

@ -374,7 +374,7 @@ This variable is buffer local and only used in the *cvs* buffer.")
("r" . cvs-mode-remove)
("s" . cvs-mode-status)
("t" . cvs-mode-tag)
;;("v" . cvs-mode-diff-vendor)
("v" . cvs-mode-view-file)
("x" . cvs-mode-remove-handled)
;; cvstree bindings
("+" . cvs-mode-tree)

View file

@ -104,11 +104,12 @@ BUF is assumed to be a temporary buffer used from the buffer MAINBUF."
(condition-case ()
(delete-window win)
(error (iconify-frame (window-frame win))))
(if (and mainbuf (get-buffer-window mainbuf))
;; FIXME: if the buffer popped into a pre-existing window,
;; we don't want to delete that window.
t ;;(delete-window win)
))))
;;; (if (and mainbuf (get-buffer-window mainbuf))
;;; ;; FIXME: if the buffer popped into a pre-existing window,
;;; ;; we don't want to delete that window.
;;; t ;;(delete-window win)
;;; )
)))
(with-current-buffer buf
(bury-buffer (unless (and (eq buf (window-buffer (selected-window)))
(not (window-dedicated-p (selected-window))))

View file

@ -1925,6 +1925,18 @@ to hear about anymore."
(cvs-mode-find-file e 'dont-select))
(defun cvs-mode-view-file (e)
"View the file."
(interactive (list last-input-event))
(cvs-mode-find-file e nil t))
(defun cvs-mode-view-file-other-window (e)
"View the file."
(interactive (list last-input-event))
(cvs-mode-find-file e t t))
(defun cvs-find-modif (fi)
(with-temp-buffer
(call-process cvs-program nil (current-buffer) nil
@ -1935,7 +1947,7 @@ to hear about anymore."
1)))
(defun cvs-mode-find-file (e &optional other)
(defun cvs-mode-find-file (e &optional other view)
"Select a buffer containing the file.
With a prefix, opens the buffer in an OTHER window."
(interactive (list last-input-event current-prefix-arg))
@ -1963,8 +1975,10 @@ With a prefix, opens the buffer in an OTHER window."
(let ((buf (if rev (cvs-retrieve-revision fi rev)
(find-file-noselect (cvs-fileinfo->full-path fi)))))
(funcall (cond ((eq other 'dont-select) 'display-buffer)
(other 'switch-to-buffer-other-window)
(t 'switch-to-buffer))
(other
(if view 'view-buffer-other-window
'switch-to-buffer-other-window))
(t (if view 'view-buffer 'switch-to-buffer)))
buf)
(when (and cvs-find-file-and-jump (cvs-applicable-p fi 'diff-base))
(goto-line (cvs-find-modif fi)))

View file

@ -866,20 +866,6 @@ Returns the compilation buffer created."
(if (eq mode t)
(prog1 "compilation" (require 'comint))
(replace-regexp-in-string "-mode$" "" (symbol-name mode))))
(process-environment
(append
compilation-environment
(if (if (boundp 'system-uses-terminfo) ; `if' for compiler warning
system-uses-terminfo)
(list "TERM=dumb" "TERMCAP="
(format "COLUMNS=%d" (window-width)))
(list "TERM=emacs"
(format "TERMCAP=emacs:co#%d:tc=unknown:"
(window-width))))
;; Set the EMACS variable, but
;; don't override users' setting of $EMACS.
(unless (getenv "EMACS") '("EMACS=t"))
(copy-sequence process-environment)))
cd-path ; in case process-environment contains CDPATH
(thisdir (if (string-match "^\\s *cd\\s +\\(.+?\\)\\s *[;&\n]" command)
(substitute-in-file-name (match-string 1 command))
@ -903,18 +889,18 @@ Returns the compilation buffer created."
(error nil))
(error "Cannot have two processes in `%s' at once"
(buffer-name)))))
;; Clear out the compilation buffer and make it writable.
;; Change its default-directory to the directory where the compilation
;; will happen, and insert a `default-directory' to indicate this.
(setq buffer-read-only nil)
(buffer-disable-undo (current-buffer))
(erase-buffer)
(buffer-enable-undo (current-buffer))
(cd thisdir)
;; output a mode setter, for saving and later reloading this buffer
(insert "-*- mode: " name-of-mode
"; default-directory: " (prin1-to-string default-directory)
" -*-\n" command "\n")
;; Make compilation buffer read-only. The filter can still write it.
;; Clear out the compilation buffer.
(let ((inhibit-read-only t))
(erase-buffer)
;; Change its default-directory to the directory where the compilation
;; will happen, and insert a `cd' command to indicate this.
(setq default-directory thisdir)
;; output a mode setter, for saving and later reloading this buffer
(insert "-*- mode: " name-of-mode
"; default-directory: " (prin1-to-string default-directory)
" -*-\n" command "\n"))
(set-buffer-modified-p nil))
;; If we're already in the compilation buffer, go to the end
;; of the buffer, so point will track the compilation output.
@ -923,70 +909,83 @@ Returns the compilation buffer created."
;; Pop up the compilation buffer.
(setq outwin (display-buffer outbuf nil t))
(with-current-buffer outbuf
(if (not (eq mode t))
(funcall mode)
(with-no-warnings (comint-mode))
(compilation-shell-minor-mode))
;; In what way is it non-ergonomic ? -stef
;; (toggle-read-only 1) ;;; Non-ergonomic.
(if highlight-regexp
(set (make-local-variable 'compilation-highlight-regexp)
highlight-regexp))
(set (make-local-variable 'compilation-arguments)
(list command mode name-function highlight-regexp))
(set (make-local-variable 'revert-buffer-function)
'compilation-revert-buffer)
(set-window-start outwin (point-min))
(or (eq outwin (selected-window))
(set-window-point outwin (if compilation-scroll-output
(point)
(point-min))))
;; The setup function is called before compilation-set-window-height
;; so it can set the compilation-window-height buffer locally.
(if compilation-process-setup-function
(funcall compilation-process-setup-function))
(compilation-set-window-height outwin)
;; Start the compilation.
(if (fboundp 'start-process)
(let ((proc (if (eq mode t)
(get-buffer-process
(with-no-warnings
(comint-exec outbuf (downcase mode-name)
shell-file-name nil `("-c" ,command))))
(start-process-shell-command (downcase mode-name)
outbuf command))))
;; Make the buffer's mode line show process state.
(setq mode-line-process '(":%s"))
(set-process-sentinel proc 'compilation-sentinel)
(set-process-filter proc 'compilation-filter)
(set-marker (process-mark proc) (point) outbuf)
(setq compilation-in-progress
(cons proc compilation-in-progress)))
;; No asynchronous processes available.
(message "Executing `%s'..." command)
;; Fake modeline display as if `start-process' were run.
(setq mode-line-process ":run")
(force-mode-line-update)
(sit-for 0) ; Force redisplay
(let ((status (call-process shell-file-name nil outbuf nil "-c"
command)))
(cond ((numberp status)
(compilation-handle-exit 'exit status
(if (zerop status)
"finished\n"
(format "\
(let ((process-environment
(append
compilation-environment
(if (if (boundp 'system-uses-terminfo) ; `if' for compiler warning
system-uses-terminfo)
(list "TERM=dumb" "TERMCAP="
(format "COLUMNS=%d" (window-width)))
(list "TERM=emacs"
(format "TERMCAP=emacs:co#%d:tc=unknown:"
(window-width))))
;; Set the EMACS variable, but
;; don't override users' setting of $EMACS.
(unless (getenv "EMACS") '("EMACS=t"))
(copy-sequence process-environment))))
(if (not (eq mode t))
(funcall mode)
(setq buffer-read-only nil)
(with-no-warnings (comint-mode))
(compilation-shell-minor-mode))
(if highlight-regexp
(set (make-local-variable 'compilation-highlight-regexp)
highlight-regexp))
(set (make-local-variable 'compilation-arguments)
(list command mode name-function highlight-regexp))
(set (make-local-variable 'revert-buffer-function)
'compilation-revert-buffer)
(set-window-start outwin (point-min))
(or (eq outwin (selected-window))
(set-window-point outwin (if compilation-scroll-output
(point)
(point-min))))
;; The setup function is called before compilation-set-window-height
;; so it can set the compilation-window-height buffer locally.
(if compilation-process-setup-function
(funcall compilation-process-setup-function))
(compilation-set-window-height outwin)
;; Start the compilation.
(if (fboundp 'start-process)
(let ((proc (if (eq mode t)
(get-buffer-process
(with-no-warnings
(comint-exec outbuf (downcase mode-name)
shell-file-name nil `("-c" ,command))))
(start-process-shell-command (downcase mode-name)
outbuf command))))
;; Make the buffer's mode line show process state.
(setq mode-line-process '(":%s"))
(set-process-sentinel proc 'compilation-sentinel)
(set-process-filter proc 'compilation-filter)
(set-marker (process-mark proc) (point) outbuf)
(setq compilation-in-progress
(cons proc compilation-in-progress)))
;; No asynchronous processes available.
(message "Executing `%s'..." command)
;; Fake modeline display as if `start-process' were run.
(setq mode-line-process ":run")
(force-mode-line-update)
(sit-for 0) ; Force redisplay
(let ((status (call-process shell-file-name nil outbuf nil "-c"
command)))
(cond ((numberp status)
(compilation-handle-exit 'exit status
(if (zerop status)
"finished\n"
(format "\
exited abnormally with code %d\n"
status))))
((stringp status)
(compilation-handle-exit 'signal status
(concat status "\n")))
(t
(compilation-handle-exit 'bizarre status status))))
;; Without async subprocesses, the buffer is not yet
;; fontified, so fontify it now.
(let ((font-lock-verbose nil)) ; shut up font-lock messages
(font-lock-fontify-buffer))
(message "Executing `%s'...done" command)))
status))))
((stringp status)
(compilation-handle-exit 'signal status
(concat status "\n")))
(t
(compilation-handle-exit 'bizarre status status))))
;; Without async subprocesses, the buffer is not yet
;; fontified, so fontify it now.
(let ((font-lock-verbose nil)) ; shut up font-lock messages
(font-lock-fontify-buffer))
(message "Executing `%s'...done" command))))
(if (buffer-local-value 'compilation-scroll-output outbuf)
(save-selected-window
(select-window outwin)
@ -1108,7 +1107,7 @@ from a different message."
:version "21.4")
;;;###autoload
(defun compilation-mode ()
(defun compilation-mode (&optional name-of-mode)
"Major mode for compilation log buffers.
\\<compilation-mode-map>To visit the source for a line-numbered error,
move point to the error message line and type \\[compile-goto-error].
@ -1121,7 +1120,7 @@ Runs `compilation-mode-hook' with `run-hooks' (which see).
(kill-all-local-variables)
(use-local-map compilation-mode-map)
(setq major-mode 'compilation-mode
mode-name "Compilation")
mode-name (or name-of-mode "Compilation"))
(set (make-local-variable 'page-delimiter)
compilation-page-delimiter)
(compilation-setup)
@ -1187,6 +1186,7 @@ If nil, use the beginning of buffer.")
"Prepare the buffer for the compilation parsing commands to work.
Optional argument MINOR indicates this is called from
`compilation-minor-mode'."
(setq buffer-read-only t)
(make-local-variable 'compilation-current-error)
(make-local-variable 'compilation-messages-start)
(make-local-variable 'compilation-error-screen-columns)
@ -1248,7 +1248,7 @@ Turning the mode on runs the normal hook `compilation-minor-mode-hook'."
(defun compilation-handle-exit (process-status exit-status msg)
"Write MSG in the current buffer and hack its mode-line-process."
(let ((buffer-read-only nil)
(let ((inhibit-read-only t)
(status (if compilation-exit-message-function
(funcall compilation-exit-message-function
process-status exit-status msg)

View file

@ -946,6 +946,8 @@ With prefix arg, silently save all file-visiting buffers, then kill."
(remove-hook 'kill-buffer-query-functions 'server-kill-buffer-query-function)
(remove-hook 'kill-emacs-query-functions 'server-kill-emacs-query-function)
(remove-hook 'kill-buffer-hook 'server-kill-buffer))
(add-hook 'server-unload-hook 'server-unload-hook)
(provide 'server)

View file

@ -837,6 +837,8 @@ look for files that have been changed and need to be copied to other systems."
(symbol-function 'shadow-orig-save-buffers-kill-emacs)))
(remove-hook 'write-file-hooks 'shadow-add-to-todo))
(add-hook 'shadowfile-unload-hook 'shadowfile-unload-hook)
(provide 'shadowfile)
;;; arch-tag: e2f4cdd7-2bab-4def-9130-9e69b412b79e

View file

@ -1159,7 +1159,7 @@ where FACE is a valid face specification, as it can be used with
(emacs-version)
"\n"
:face '(variable-pitch :height 0.5)
"Copyright (C) 2002 Free Software Foundation, Inc.")
"Copyright (C) 2004 Free Software Foundation, Inc.")
(and auto-save-list-file-prefix
;; Don't signal an error if the
;; directory for auto-save-list files
@ -1325,7 +1325,7 @@ More Manuals / Ordering Manuals How to order printed manuals from the FSF.
")
(insert "\n\n" (emacs-version)
"
Copyright (C) 2002 Free Software Foundation, Inc."))
Copyright (C) 2004 Free Software Foundation, Inc."))
;; No mouse menus, so give help using kbd commands.
@ -1373,7 +1373,7 @@ If you have no Meta key, you may instead type ESC followed by the character.)")
(insert "\n\n" (emacs-version)
"
Copyright (C) 2002 Free Software Foundation, Inc.")
Copyright (C) 2004 Free Software Foundation, Inc.")
(if (and (eq (key-binding "\C-h\C-c") 'describe-copying)
(eq (key-binding "\C-h\C-d") 'describe-distribution)

View file

@ -1354,7 +1354,8 @@ If STROKES-MAP is not given, `strokes-global-map' will be used instead."
:color-symbols
`(("foreground"
. ,(frame-parameter nil 'foreground-color))))))
finally do (kill-region (1+ (point)) (point-max)))
finally do (unless (eobp)
(kill-region (1+ (point)) (point-max))))
(view-buffer "*Strokes List*" nil)
(set (make-local-variable 'view-mode-map)
(let ((map (copy-keymap view-mode-map)))
@ -1745,6 +1746,8 @@ Store XPM in buffer BUFNAME if supplied \(default is ` *strokes-xpm*'\)"
(strokes-mode -1)
(remove-hook 'kill-emacs-query-functions 'strokes-prompt-user-save-strokes))
(add-hooks 'strokes-unload-hook 'strokes-unload-hook)
(run-hooks 'strokes-load-hook)
(provide 'strokes)

View file

@ -1212,51 +1212,59 @@ any other non-digit terminates the character code and is then used as input."))
code))
(defun read-passwd (prompt &optional confirm default)
"Read a password, prompting with PROMPT. Echo `.' for each character typed.
End with RET, LFD, or ESC. DEL or C-h rubs out. C-u kills line.
If optional CONFIRM is non-nil, read password twice to make sure.
Optional DEFAULT is a default password to use instead of empty input."
(if confirm
(let (success)
(while (not success)
(let ((first (read-passwd prompt nil default))
(second (read-passwd "Confirm password: " nil default)))
(if (equal first second)
(progn
(and (arrayp second) (clear-string second))
(setq success first))
(and (arrayp first) (clear-string first))
(and (arrayp second) (clear-string second))
(message "Password not repeated accurately; please start over")
(sit-for 1))))
success)
(let ((pass nil)
(c 0)
(echo-keystrokes 0)
(cursor-in-echo-area t))
(while (progn (message "%s%s"
prompt
(make-string (length pass) ?.))
(setq c (read-char-exclusive nil t))
(and (/= c ?\r) (/= c ?\n) (/= c ?\e)))
(clear-this-command-keys)
(if (= c ?\C-u)
(progn
(and (arrayp pass) (clear-string pass))
(setq pass ""))
(if (and (/= c ?\b) (/= c ?\177))
(let* ((new-char (char-to-string c))
(new-pass (concat pass new-char)))
"Read a password, prompting with PROMPT, and return it.
If optional CONFIRM is non-nil, read the password twice to make sure.
Optional DEFAULT is a default password to use instead of empty input.
This function echoes `.' for each character that the user types.
The user ends with RET, LFD, or ESC. DEL or C-h rubs out. C-u kills line.
C-g quits; if `inhibit-quit' was non-nil around this function,
then it returns nil if the user types C-g.
Once the caller uses the password, it can erase the password
by doing (clear-string STRING)."
(with-local-quit
(if confirm
(let (success)
(while (not success)
(let ((first (read-passwd prompt nil default))
(second (read-passwd "Confirm password: " nil default)))
(if (equal first second)
(progn
(and (arrayp second) (clear-string second))
(setq success first))
(and (arrayp first) (clear-string first))
(and (arrayp second) (clear-string second))
(message "Password not repeated accurately; please start over")
(sit-for 1))))
success)
(let ((pass nil)
(c 0)
(echo-keystrokes 0)
(cursor-in-echo-area t))
(while (progn (message "%s%s"
prompt
(make-string (length pass) ?.))
(setq c (read-char-exclusive nil t))
(and (/= c ?\r) (/= c ?\n) (/= c ?\e)))
(clear-this-command-keys)
(if (= c ?\C-u)
(progn
(and (arrayp pass) (clear-string pass))
(clear-string new-char)
(setq c ?\0)
(setq pass new-pass))
(if (> (length pass) 0)
(let ((new-pass (substring pass 0 -1)))
(setq pass ""))
(if (and (/= c ?\b) (/= c ?\177))
(let* ((new-char (char-to-string c))
(new-pass (concat pass new-char)))
(and (arrayp pass) (clear-string pass))
(setq pass new-pass))))))
(message nil)
(or pass default ""))))
(clear-string new-char)
(setq c ?\0)
(setq pass new-pass))
(if (> (length pass) 0)
(let ((new-pass (substring pass 0 -1)))
(and (arrayp pass) (clear-string pass))
(setq pass new-pass))))))
(message nil)
(or pass default "")))))
;; This should be used by `call-interactively' for `n' specs.
(defun read-number (prompt &optional default)
@ -1834,14 +1842,14 @@ See also `with-temp-file' and `with-output-to-string'."
(defmacro with-local-quit (&rest body)
"Execute BODY, allowing quits to terminate BODY but not escape further.
When a quit terminates BODY, `with-local-quit' requests another quit when
it finishes. That quit will be processed in turn, the next time quitting
is again allowed."
When a quit terminates BODY, `with-local-quit' returns nil but
requests another quit. That quit will be processed, the next time quitting
is allowed once again."
(declare (debug t) (indent 0))
`(condition-case nil
(let ((inhibit-quit nil))
,@body)
(quit (setq quit-flag t))))
(quit (setq quit-flag t) nil)))
(defmacro combine-after-change-calls (&rest body)
"Execute BODY, but don't call the after-change functions till the end.
@ -2035,11 +2043,12 @@ STRING should be given if the last search was by `string-match' on STRING."
(defun looking-back (regexp &optional limit)
"Return non-nil if text before point matches regular expression REGEXP.
Like `looking-at' except backwards and slower.
Like `looking-at' except matches before point, and is slower.
LIMIT if non-nil speeds up the search by specifying how far back the
match can start."
(save-excursion
(re-search-backward (concat "\\(?:" regexp "\\)\\=") limit t)))
(not (null
(save-excursion
(re-search-backward (concat "\\(?:" regexp "\\)\\=") limit t)))))
(defconst split-string-default-separators "[ \f\t\n\r\v]+"
"The default value of separators for `split-string'.

View file

@ -2,7 +2,8 @@
;;; Copyright (C) 1988, 1990, 1992, 1994, 1995, 2004 Free Software Foundation, Inc.
;; Author: Per Bothner <bothner@cygnus.com>
;; Author: Per Bothner <per@bothner.com>
;; Maintainer: Dan Nicolaescu <dann@ics.uci.edu>, Per Bothner <per@bothner.com>
;; Based on comint mode written by: Olin Shivers <shivers@cs.cmu.edu>
;; Keywords: processes

View file

@ -1618,10 +1618,11 @@ Global `ispell-quit' set to start location to continue spell session."
(set-buffer (get-buffer-create ispell-choices-buffer))
(setq mode-line-format (concat "-- %b -- word: " word))
;; XEmacs: no need for horizontal scrollbar in choices window
(and (fboundp 'set-specifier)
(boundp 'horizontal-scrollbar-visible-p)
(set-specifier horizontal-scrollbar-visible-p nil
(cons (current-buffer) nil)))
(with-no-warnings
(and (fboundp 'set-specifier)
(boundp 'horizontal-scrollbar-visible-p)
(set-specifier horizontal-scrollbar-visible-p nil
(cons (current-buffer) nil))))
(erase-buffer)
(if guess
(progn
@ -1871,7 +1872,7 @@ Global `ispell-quit' set to start location to continue spell session."
(if (and ispell-use-framepop-p (fboundp 'framepop-display-buffer))
(progn
(framepop-display-buffer (get-buffer ispell-choices-buffer))
(get-buffer-window ispell-choices-buffer t)
;;; (get-buffer-window ispell-choices-buffer t)
(select-window (previous-window))) ; *Choices* window
;; standard selection by splitting a small buffer out of this window.
(let ((choices-window (get-buffer-window ispell-choices-buffer)))
@ -2355,7 +2356,7 @@ Keeps argument list for future ispell invocations for no async support."
(if extended-char-mode ; ~ extended character mode
(ispell-send-string (concat extended-char-mode "\n"))))
(if ispell-async-processp
(process-kill-without-query ispell-process))))
(set-process-query-on-exit-flag ispell-process nil))))
;;;###autoload
(defun ispell-kill-ispell (&optional no-error)
@ -3286,19 +3287,23 @@ You can bind this to the key C-c i in GNUS or mail by adding to
(cond
((functionp 'sc-cite-regexp) ; sc 3.0
(concat "\\(" (sc-cite-regexp) "\\)" "\\|"
(ispell-non-empty-string sc-reference-tag-string)))
(with-no-warnings
(ispell-non-empty-string sc-reference-tag-string))))
((boundp 'sc-cite-regexp) ; sc 2.3
(concat "\\(" sc-cite-regexp "\\)" "\\|"
(ispell-non-empty-string sc-reference-tag-string)))
(with-no-warnings
(ispell-non-empty-string sc-reference-tag-string))))
((or (equal major-mode 'news-reply-mode) ;GNUS 4 & below
(equal major-mode 'message-mode)) ;GNUS 5
(concat "In article <" "\\|"
"[^,;&+=\n]+ <[^,;&+=]+> writes:" "\\|"
message-cite-prefix-regexp "\\|"
(with-no-warnings message-cite-prefix-regexp)
"\\|"
default-prefix))
((equal major-mode 'mh-letter-mode) ; mh mail message
(concat "[^,;&+=\n]+ writes:" "\\|"
(ispell-non-empty-string mh-ins-buf-prefix)))
(with-no-warnings
(ispell-non-empty-string mh-ins-buf-prefix))))
((not internal-messagep) ; Assume nn sent us this message.
(concat "In [a-zA-Z.]+ you write:" "\\|"
"In <[^,;&+=]+> [^,;&+=]+ writes:" "\\|"

View file

@ -1,3 +1,25 @@
2004-10-16 Richard M. Stallman <rms@gnu.org>
* url.el (url-do-setup): Don't set url-passwd-entry-func.
* url-vars.el (url-passwd-entry-func): Var deleted.
(mm-mime-mule-charset-alist): Remove compatibility code for old Gnus.
(url-weekday-alist): Renamed from weekday-alist.
(url-monthabbrev-alist): Renamed from monthabbrev-alist.
(url-vars-unload-hook): Initialize hook var to hold the function.
* url-util.el (url-get-normalized-date): Use
url-weekday-alist and url-monthabbrev-alist.
* url-misc.el: Load cl at compile time.
* url-mailto.el: Don't load cl.
(url-mailto): Fix call to `push'.
* url-gw.el (url-open-telnet): Use read-passwd.
* url-auth.el (url-basic-auth, url-digest-auth): Use read-passwd.
2004-10-12 Simon Josefsson <jas@extundo.com>
* url-vars.el (url-gateway-method): Add new method `tls'.

View file

@ -78,7 +78,7 @@ instead of the pathname inheritance method."
((and prompt (not byserv))
(setq user (read-string (url-auth-user-prompt url realm)
(user-real-login-name))
pass (funcall url-passwd-entry-func "Password: "))
pass (read-passwd "Password: "))
(set url-basic-auth-storage
(cons (list server
(cons path
@ -102,7 +102,7 @@ instead of the pathname inheritance method."
(progn
(setq user (read-string (url-auth-user-prompt url realm)
(user-real-login-name))
pass (funcall url-passwd-entry-func "Password: ")
pass (read-passwd "Password: ")
retval (base64-encode-string (format "%s:%s" user pass))
byserv (assoc server (symbol-value url-basic-auth-storage)))
(setcdr byserv
@ -160,7 +160,7 @@ instead of hostname:portnum."
((and prompt (not byserv))
(setq user (read-string (url-auth-user-prompt url realm)
(user-real-login-name))
pass (funcall url-passwd-entry-func "Password: ")
pass (read-passwd "Password: ")
url-digest-auth-storage
(cons (list server
(cons path
@ -187,7 +187,7 @@ instead of hostname:portnum."
(progn
(setq user (read-string (url-auth-user-prompt url realm)
(user-real-login-name))
pass (funcall url-passwd-entry-func "Password: ")
pass (read-passwd "Password: ")
retval (setq retval
(cons user
(url-digest-auth-create-key

View file

@ -186,7 +186,7 @@ linked Emacs under SunOS 4.x"
proc (concat
(or url-gateway-telnet-password
(setq url-gateway-telnet-password
(funcall url-passwd-entry-func "Password: ")))
(read-passwd "Password: ")))
"\n"))
(erase-buffer)
(url-wait-for-string url-gateway-prompt-pattern proc)

View file

@ -25,7 +25,6 @@
;;; Code:
(eval-when-compile (require 'cl))
(require 'url-vars)
(require 'url-parse)
(require 'url-util)
@ -85,7 +84,7 @@
(setq args (cons (list "x-url-from" source-url) args)))
(if (assoc "to" args)
(push to (cdr (assoc "to" args)))
(push (cdr (assoc "to" args)) to)
(setq args (cons (list "to" to) args)))
(setq subject (cdr-safe (assoc "subject" args)))
(if (fboundp url-mail-command) (funcall url-mail-command) (mail))

View file

@ -22,6 +22,7 @@
;;; Boston, MA 02111-1307, USA.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(eval-when-compile (require 'cl))
(require 'url-vars)
(require 'url-parse)
(autoload 'Info-goto-node "info" "" t)

View file

@ -192,13 +192,13 @@ Will not do anything if `url-show-status' is nil."
(nth 1 (current-time-zone))
"GMT"))
(parsed (timezone-parse-date gmt))
(day (cdr-safe (assoc (substring raw 0 3) weekday-alist)))
(day (cdr-safe (assoc (substring raw 0 3) url-weekday-alist)))
(year nil)
(month (car
(rassoc
(string-to-int (aref parsed 1)) monthabbrev-alist)))
(string-to-int (aref parsed 1)) url-monthabbrev-alist)))
)
(setq day (or (car-safe (rassoc day weekday-alist))
(setq day (or (car-safe (rassoc day url-weekday-alist))
(substring raw 0 3))
year (aref parsed 0))
;; This is needed for plexus servers, or the server will hang trying to

View file

@ -191,19 +191,6 @@ from the ACCESS_proxy environment variables."
(string :tag "Proxy")))
:group 'url)
(defcustom url-passwd-entry-func nil
"*Symbol indicating which function to call to read in a password.
It will be set up depending on whether you are running EFS or ange-ftp
at startup if it is nil. This function should accept the prompt
string as its first argument, and the default value as its second
argument."
:type '(choice (const :tag "Guess" :value nil)
(const :tag "Use Ange-FTP" :value ange-ftp-read-passwd)
(const :tag "Use EFS" :value efs-read-passwd)
(const :tag "Use Password Package" :value read-passwd)
(function :tag "Other"))
:group 'url-hairy)
(defcustom url-standalone-mode nil
"*Rely solely on the cache?"
:type 'boolean
@ -240,24 +227,6 @@ Should be an assoc list of headers/contents.")
(defvar url-mime-encoding-string nil
"*String to send in the Accept-encoding: field in HTTP requests.")
;; `mm-mime-mule-charset-alist' in Gnus 5.8/9 contains elements whose
;; cars aren't valid MIME charsets/coding systems, at least in Emacs.
;; This gets it correct by construction in Emacs. Fixme: DTRT for
;; XEmacs -- its `coding-system-list' doesn't have the BASE-ONLY arg.
(when (and (not (featurep 'xemacs))
(fboundp 'coding-system-list))
(setq mm-mime-mule-charset-alist
(apply
'nconc
(mapcar
(lambda (cs)
(when (and (coding-system-get cs 'mime-charset)
(not (eq t (coding-system-get cs 'safe-charsets))))
(list (cons (coding-system-get cs 'mime-charset)
(delq 'ascii
(coding-system-get cs 'safe-charsets))))))
(coding-system-list 'base-only)))))
;; Perhaps the first few should actually be given decreasing `q's and
;; the list should be trimmed significantly.
;; Fixme: do something sane if we don't have `sort-coding-systems'
@ -381,14 +350,14 @@ Currently supported methods:
(defvar url-setup-done nil "Has setup configuration been done?")
(defconst weekday-alist
(defconst url-weekday-alist
'(("Sunday" . 0) ("Monday" . 1) ("Tuesday" . 2) ("Wednesday" . 3)
("Thursday" . 4) ("Friday" . 5) ("Saturday" . 6)
("Tues" . 2) ("Thurs" . 4)
("Sun" . 0) ("Mon" . 1) ("Tue" . 2) ("Wed" . 3)
("Thu" . 4) ("Fri" . 5) ("Sat" . 6)))
(defconst monthabbrev-alist
(defconst url-monthabbrev-alist
'(("Jan" . 1) ("Feb" . 2) ("Mar" . 3) ("Apr" . 4) ("May" . 5) ("Jun" . 6)
("Jul" . 7) ("Aug" . 8) ("Sep" . 9) ("Oct" . 10) ("Nov" . 11)
("Dec" . 12)))
@ -425,6 +394,8 @@ This should be set, e.g. by mail user agents rendering HTML to avoid
(defun url-vars-unload-hook ()
(remove-hook 'set-language-environment-hook 'url-set-mime-charset-string))
(add-hook 'url-vars-unload-hook 'url-vars-unload-hook)
(provide 'url-vars)
;;; arch-tag: 29205e5f-c5ce-433c-8d5d-38cbaed64b49

View file

@ -113,26 +113,6 @@ Emacs."
noproxy "") "\\)"))
url-proxy-services))))
;; Set the password entry funtion based on user defaults or guess
;; based on which remote-file-access package they are using.
(cond
(url-passwd-entry-func nil) ; Already been set
((fboundp 'read-passwd) ; Use secure password if available
(setq url-passwd-entry-func 'read-passwd))
((or (featurep 'efs) ; Using EFS
(featurep 'efs-auto)) ; or autoloading efs
(if (not (fboundp 'read-passwd))
(autoload 'read-passwd "passwd" "Read in a password" nil))
(setq url-passwd-entry-func 'read-passwd))
((or (featurep 'ange-ftp) ; Using ange-ftp
(and (boundp 'file-name-handler-alist)
(not (featurep 'xemacs)))) ; ??
(setq url-passwd-entry-func 'ange-ftp-read-passwd))
(t
(url-warn
'security
"(url-setup): Can't determine how to read passwords, winging it.")))
(url-setup-privacy-info)
(run-hooks 'url-load-hook)
(setq url-setup-done t)))

View file

@ -283,8 +283,8 @@ Return non-nil if FILE is unchanged."
(setq logdir (expand-file-name version logdir))
(setq logdir (expand-file-name archive logdir))
(setq logdir (expand-file-name "patch-log" logdir))
;; Revision names go: base-0, patch-N, version-0, versionfix-N.
(dolist (file (directory-files logdir))
(dolist (file (if (file-directory-p logdir) (directory-files logdir)))
;; Revision names go: base-0, patch-N, version-0, versionfix-M.
(when (and (eq (aref file 0) ?v) (not sealed))
(setq sealed t rev-nb 0))
(if (and (string-match "-\\([0-9]+\\)\\'" file)

View file

@ -754,8 +754,8 @@ current, and kill the buffer that visits the link."
(set (make-local-variable 'backup-inhibited) t))
;; Let the backend setup any buffer-local things he needs.
(vc-call-backend (vc-backend buffer-file-name) 'find-file-hook))
((let* ((link (file-symlink-p buffer-file-name))
(link-type (and link (vc-backend (file-chase-links link)))))
((let ((link-type (and (file-symlink-p buffer-file-name)
(vc-backend (file-chase-links buffer-file-name)))))
(cond ((not link-type) nil) ;Nothing to do.
((eq vc-follow-symlinks nil)
(message

View file

@ -117,12 +117,12 @@ functions that enable or disable view mode.")
(defvar view-page-size nil
"Default number of lines to scroll by View page commands.
If nil then the local value of this is initially set to window size.")
If nil that means use the window size.")
(make-variable-buffer-local 'view-page-size)
(defvar view-half-page-size nil
"Default number of lines to scroll by View half page commands.
If nil then the local value of this is initially set to half window size.")
If nil that means use half the window size.")
(make-variable-buffer-local 'view-half-page-size)
(defvar view-last-regexp nil)
@ -453,8 +453,8 @@ Entry to view-mode runs the normal hook `view-mode-hook'."
;; This is to guarantee that the buffer-read-only variable is restored.
(add-hook 'change-major-mode-hook 'view-mode-disable nil t)
(setq view-mode t
view-page-size (view-page-size-default view-page-size)
view-half-page-size (or view-half-page-size (/ (view-window-size) 2))
view-page-size nil
view-half-page-size nil
view-old-buffer-read-only buffer-read-only
buffer-read-only t
view-old-Helper-return-blurb (and (boundp 'Helper-return-blurb)
@ -675,7 +675,8 @@ previous state and go to previous buffer or window."
(defun view-set-half-page-size-default (lines)
;; Get and maybe set half page size.
(if (not lines) view-half-page-size
(if (not lines) (or view-half-page-size
(/ (view-window-size) 2))
(setq view-half-page-size
(if (zerop (setq lines (prefix-numeric-value lines)))
(/ (view-window-size) 2)
@ -803,13 +804,13 @@ Exit if end of text is visible and `view-scroll-auto-exit' is non-nil.
\\[View-scroll-page-backward-set-page-size].
If LINES is more than a window-full, only the last window-full is shown."
(interactive "P")
(view-scroll-lines lines nil view-page-size nil))
(view-scroll-lines lines nil (view-page-size-default view-page-size) nil))
(defun View-scroll-page-backward (&optional lines)
"Scroll \"page size\" or prefix LINES lines backward in View mode.
See also `View-scroll-page-forward'."
(interactive "P")
(view-scroll-lines lines t view-page-size nil))
(view-scroll-lines lines t (view-page-size-default view-page-size) nil))
(defun View-scroll-page-forward-set-page-size (&optional lines)
"Scroll forward LINES lines in View mode, setting the \"page size\".

View file

@ -859,6 +859,8 @@ This is meant to be added buffer-locally to `write-file-functions'."
(remove-hook 'write-file-functions 'whitespace-write-file-hook t)
(remove-hook 'kill-buffer-hook 'whitespace-buffer))
(add-hook 'whitespace-unload-hook 'whitespace-unload-hook)
(provide 'whitespace)
;;; arch-tag: 4ff44e87-b63c-402d-95a6-15e51e58bd0c

View file

@ -1,3 +1,21 @@
2004-10-18 Luc Teirlinck <teirllm@auburn.edu>
* calc.texi (Reporting Bugs): Double up `@'.
2004-10-15 Reiner Steib <Reiner.Steib@gmx.de>
* gnus.texi (New Features): Add 5.11.
* message.texi (Resending): Remove wrong default value.
* gnus.texi (Mail Source Specifiers): Describe possible problems
of `pop3-leave-mail-on-server'. Add `pop3-movemail' and
`pop3-leave-mail-on-server' to the index.
2004-10-15 Katsumi Yamaoka <yamaoka@jpl.org>
* message.texi (Canceling News): Add how to set a password.
2004-10-12 Reiner Steib <Reiner.Steib@gmx.de>
* gnus-faq.texi ([5.9]): Improve code for reply-in-news.

View file

@ -34286,11 +34286,10 @@ press @kbd{M-# t} to begin.
@appendix Reporting Bugs
@noindent
If you find a bug in Calc, send e-mail to Colin Walters,
If you find a bug in Calc, send e-mail to Jay Belanger,
@example
walters@@debian.org @r{or}
walters@@verbum.org
belanger@@truman.edu
@end example
@noindent

View file

@ -885,7 +885,7 @@ New Features
* Red Gnus:: Third time best---Gnus 5.4/5.5.
* Quassia Gnus:: Two times two is four, or Gnus 5.6/5.7.
* Pterodactyl Gnus:: Pentad also starts with P, AKA Gnus 5.8/5.9.
* Oort Gnus:: It's big. It's far out. Gnus 5.10.
* Oort Gnus:: It's big. It's far out. Gnus 5.10/5.11.
Customization
@ -13538,10 +13538,16 @@ and says what authentication scheme to use. The default is
@end table
@vindex pop3-movemail
@vindex pop3-leave-mail-on-server
If the @code{:program} and @code{:function} keywords aren't specified,
@code{pop3-movemail} will be used. If the
@code{pop3-leave-mail-on-server} is non-@code{nil} the mail is to be
left on the POP server after fetching.
left on the @acronym{POP} server after fetching when using
@code{pop3-movemail}. Note that POP servers maintain no state
information between sessions, so what the client believes is there and
what is actually there may not match up. If they do not, then the whole
thing can fall apart and leave you with a corrupt mailbox.
Here are some examples. Fetch from the default @acronym{POP} server,
using the default user name, and default fetcher:
@ -25050,7 +25056,7 @@ actually are people who are using Gnus. Who'd'a thunk it!
* Red Gnus:: Third time best---Gnus 5.4/5.5.
* Quassia Gnus:: Two times two is four, or Gnus 5.6/5.7.
* Pterodactyl Gnus:: Pentad also starts with P, AKA Gnus 5.8/5.9.
* Oort Gnus:: It's big. It's far out. Gnus 5.10.
* Oort Gnus:: It's big. It's far out. Gnus 5.10/5.11.
@end menu
These lists are, of course, just @emph{short} overviews of the

View file

@ -224,7 +224,13 @@ only you can cancel your own messages, which is nice. The downside
is that if you lose your @file{.emacs} file (which is where Gnus
stores the secret cancel lock password (which is generated
automatically the first time you use this feature)), you won't be
able to cancel your message.
able to cancel your message. If you yourself want to manage a password,
you can put something like the following in your @file{~/.gnus.el} file:
@lisp
(setq canlock-password "Salam Shalom"
canlock-password-for-verify canlock-password)
@end lisp
Whether to insert the header or not is controlled by the
@code{message-insert-canlock} variable.
@ -309,8 +315,7 @@ and resend the message in the current buffer to that address.
@vindex message-ignored-resent-headers
Headers that match the @code{message-ignored-resent-headers} regexp will
be removed before sending the message. The default is
@samp{^Return-receipt}.
be removed before sending the message.
@node Bouncing

View file

@ -16,6 +16,9 @@
fixing first. The easiest way to do this and avoid future conflicts
is to run the following command in this (emacs/nt) directory:
cvs update -kb
In addition to this file, you should also read INSTALL.CVS in the
parent directory, and make sure that you have a version of "touch.exe"
in your path, and that it will create files that do not yet exist.
To compile Emacs, you will need either Microsoft Visual C++ 2.0 or
later and nmake, or a Windows port of GCC 2.95 or later with Mingw
@ -31,10 +34,14 @@
like this, we recommend the use of the supported compilers mentioned
in the previous paragraph.
You will also need a copy of the Posix cp, rm and mv programs. These
and other useful Posix utilities can be obtained from the Mingw or
Cygwin projects.
If you build Emacs on Windows 9X or ME, not on Windows 2K/XP or
Windows NT, we suggest to install the Cygwin port of Bash.
Please see http://www.mingw.org for pointers to GCC/Mingw binaries.
Please see http://www.mingw.org for pointers to GCC/Mingw and binaries.
For reference, here is a list of which builds of GNU make are known
to work or not, and whether they work in the presence and/or absence

View file

@ -1,7 +1,58 @@
2004-10-18 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
* gtkutil.c (xg_update_scrollbar_pos): Change XClearWindow to
gdk_window_clear and move gdk_window_process_all_updates after
clear so events are sent to the X server in correct order.
2004-10-18 Kenichi Handa <handa@m17n.org>
* fontset.c (fs_load_font): Use fast_string_match_ignore_case for
comparing font names.
(fs_query_fontset): Use fast_string_match for comparing fontset
names.
(list_fontsets): Likewise.
* search.c (fast_string_match_ignore_case): New function.
* lisp.h (fast_string_match_ignore_case): Extern it.
2004-10-17 Kim F. Storm <storm@cua.dk>
* xdisp.c (overlay_arrow_at_row): Return overlay string rather
than bitmap if there is not left fringe.
(get_overlay_arrow_glyph_row): Also used on windows system.
(display_line): Display overlay string if no left fringe.
2004-10-16 Jason Rumney <jasonr@gnu.org>
* w32fns.c (w32_font_match): Encode font name being matched.
2004-10-16 Richard M. Stallman <rms@gnu.org>
* window.c (Fspecial_display_p): Doc fix.
2004-10-15 Stefan <monnier@iro.umontreal.ca>
* doc.c (Fsubstitute_command_keys): Fix remap-handling.
Don't ignore menus, because where-is-internal already does it for us.
2004-10-15 Kim F. Storm <storm@cua.dk>
* xdisp.c (redisplay_window): Only update fringes and vertical
border on window frames.
2004-10-14 Andreas Schwab <schwab@suse.de>
* m/ia64.h (DATA_SEG_BITS): Don't define.
2004-10-14 Kim F. Storm <storm@cua.dk>
* xterm.h: Include Xutil.h after keysym.h to work around bug
(incorrectly recognising AltGr key) in some X versions.
in some X versions.
2004-10-13 Stefan Monnier <monnier@iro.umontreal.ca>
* fns.c (map_char_table): Add missing gcpros.
2004-10-13 Stefan Monnier <monnier@iro.umontreal.ca>

View file

@ -774,28 +774,18 @@ thus, \\=\\=\\=\\= puts \\=\\= into the output, and \\=\\=\\=\\[ puts \\=\\[ int
/* Save STRP in IDX. */
idx = strp - SDATA (string);
tem = Fintern (make_string (start, length_byte), Qnil);
name = Fintern (make_string (start, length_byte), Qnil);
/* Ignore remappings unless there are no ordinary bindings. */
tem = Fwhere_is_internal (tem, keymap, Qt, Qnil, Qt);
tem = Fwhere_is_internal (name, keymap, Qt, Qnil, Qt);
if (NILP (tem))
tem = Fwhere_is_internal (tem, keymap, Qt, Qnil, Qnil);
tem = Fwhere_is_internal (name, keymap, Qt, Qnil, Qnil);
/* Note the Fwhere_is_internal can GC, so we have to take
relocation of string contents into account. */
strp = SDATA (string) + idx;
start = SDATA (string) + start_idx;
/* Disregard menu bar bindings; it is positively annoying to
mention them when there's no menu bar, and it isn't terribly
useful even when there is a menu bar. */
if (!NILP (tem))
{
firstkey = Faref (tem, make_number (0));
if (EQ (firstkey, Qmenu_bar))
tem = Qnil;
}
if (NILP (tem)) /* but not on any keys */
{
int offset = bufp - buf;

View file

@ -655,7 +655,7 @@ fs_load_font (f, c, fontname, id, face)
struct face *face;
{
Lisp_Object fontset;
Lisp_Object list, elt;
Lisp_Object list, elt, fullname;
int size = 0;
struct font_info *fontp;
int charset = CHAR_CHARSET (c);
@ -701,10 +701,11 @@ fs_load_font (f, c, fontname, id, face)
font_info structure that are not set by (*load_font_func). */
fontp->charset = charset;
fullname = build_string (fontp->full_name);
fontp->vertical_centering
= (STRINGP (Vvertical_centering_font_regexp)
&& (fast_c_string_match_ignore_case
(Vvertical_centering_font_regexp, fontp->full_name) >= 0));
&& (fast_string_match_ignore_case
(Vvertical_centering_font_regexp, fullname) >= 0));
if (fontp->encoding[1] != FONT_ENCODING_NOT_DECIDED)
{
@ -721,7 +722,6 @@ fs_load_font (f, c, fontname, id, face)
/* The font itself doesn't have information about encoding. */
int i;
fontname = fontp->full_name;
/* By default, encoding of ASCII chars is 0 (i.e. 0x00..0x7F),
others is 1 (i.e. 0x80..0xFF). */
fontp->encoding[0] = 0;
@ -733,8 +733,7 @@ fs_load_font (f, c, fontname, id, face)
elt = XCAR (list);
if (CONSP (elt)
&& STRINGP (XCAR (elt)) && CONSP (XCDR (elt))
&& (fast_c_string_match_ignore_case (XCAR (elt), fontname)
>= 0))
&& (fast_string_match_ignore_case (XCAR (elt), fullname) >= 0))
{
Lisp_Object tmp;
@ -848,18 +847,17 @@ fs_query_fontset (name, regexpp)
for (i = 0; i < ASIZE (Vfontset_table); i++)
{
Lisp_Object fontset;
const unsigned char *this_name;
Lisp_Object fontset, this_name;
fontset = FONTSET_FROM_ID (i);
if (NILP (fontset)
|| !BASE_FONTSET_P (fontset))
continue;
this_name = SDATA (FONTSET_NAME (fontset));
this_name = FONTSET_NAME (fontset);
if (regexpp
? fast_c_string_match_ignore_case (name, this_name) >= 0
: !strcmp (SDATA (name), this_name))
? fast_string_match (name, this_name) >= 0
: !strcmp (SDATA (name), SDATA (this_name)))
return i;
}
return -1;
@ -913,19 +911,18 @@ list_fontsets (f, pattern, size)
for (id = 0; id < ASIZE (Vfontset_table); id++)
{
Lisp_Object fontset;
const unsigned char *name;
Lisp_Object fontset, name;
fontset = FONTSET_FROM_ID (id);
if (NILP (fontset)
|| !BASE_FONTSET_P (fontset)
|| !EQ (frame, FONTSET_FRAME (fontset)))
continue;
name = SDATA (FONTSET_NAME (fontset));
name = FONTSET_NAME (fontset);
if (!NILP (regexp)
? (fast_c_string_match_ignore_case (regexp, name) < 0)
: strcmp (SDATA (pattern), name))
? (fast_string_match (regexp, name) < 0)
: strcmp (SDATA (pattern), SDATA (name)))
continue;
if (size)

View file

@ -2888,9 +2888,6 @@ xg_update_scrollbar_pos (f, scrollbar_id, top, left, width, height,
gtk_fixed_move (GTK_FIXED (wfixed), wscroll, left, top);
gtk_widget_set_size_request (wscroll, width, height);
/* Must force out update so changed scroll bars gets redrawn. */
gdk_window_process_all_updates ();
/* Scroll bars in GTK has a fixed width, so if we say width 16, it
will only be its fixed width (14 is default) anyway, the rest is
blank. We are drawing the mode line across scroll bars when
@ -2917,9 +2914,11 @@ xg_update_scrollbar_pos (f, scrollbar_id, top, left, width, height,
scroll bar so that there is some space (typically 1 pixel) between
the scroll bar and the edge of the window and between the scroll
bar and the fringe. */
gdk_window_clear (wscroll->window);
XClearWindow (FRAME_X_DISPLAY (f), GTK_WIDGET_TO_X_WIN (wscroll));
/* Must force out update so changed scroll bars gets redrawn. */
gdk_window_process_all_updates ();
SET_FRAME_GARBAGED (f);
cancel_mouse_face (f);
}

View file

@ -2792,6 +2792,7 @@ EXFUN (Fmatch_end, 1);
EXFUN (Flooking_at, 1);
extern int fast_string_match P_ ((Lisp_Object, Lisp_Object));
extern int fast_c_string_match_ignore_case P_ ((Lisp_Object, const char *));
extern int fast_string_match_ignore_case P_ ((Lisp_Object, Lisp_Object));
extern int scan_buffer P_ ((int, int, int, int, int *, int));
extern int scan_newline P_ ((int, int, int, int, int, int));
extern int find_next_newline P_ ((int, int));

View file

@ -133,8 +133,6 @@ extern void r_alloc_free ();
#endif /* not NOT_C_CODE */
#define DATA_SEG_BITS 0x6000000000000000
#define HAVE_TEXT_START
/* arch-tag: 9b8e9fb2-2e49-4c22-b68f-11a488e77c66

View file

@ -493,6 +493,27 @@ fast_c_string_match_ignore_case (regexp, string)
immediate_quit = 0;
return val;
}
/* Like fast_string_match but ignore case. */
int
fast_string_match_ignore_case (regexp, string)
Lisp_Object regexp, string;
{
int val;
struct re_pattern_buffer *bufp;
bufp = compile_pattern (regexp, 0, Vascii_downcase_table,
0, STRING_MULTIBYTE (string));
immediate_quit = 1;
re_match_object = string;
val = re_search (bufp, (char *) SDATA (string),
SBYTES (string), 0,
SBYTES (string), 0);
immediate_quit = 0;
return val;
}
/* The newline cache: remembering which sections of text have no newlines. */

View file

@ -5370,7 +5370,7 @@ x_to_w32_font (lpxstr, lplogfont)
setup_coding_system
(Fcheck_coding_system (Vlocale_coding_system), &coding);
coding.src_multibyte = 1;
coding.dst_multibyte = 1;
coding.dst_multibyte = 0;
/* Need to set COMPOSITION_DISABLED, otherwise Emacs crashes in
encode_coding_iso2022 trying to dereference a null pointer. */
coding.composing = COMPOSITION_DISABLED;
@ -5607,12 +5607,14 @@ w32_font_match (fontname, pattern)
char * fontname;
char * pattern;
{
char *regex = alloca (strlen (pattern) * 2 + 3);
char *font_name_copy = alloca (strlen (fontname) + 1);
char *font_name_copy;
char *ptr;
Lisp_Object encoded_font_name;
char *regex = alloca (strlen (pattern) * 2 + 3);
/* Copy fontname so we can modify it during comparison. */
strcpy (font_name_copy, fontname);
/* Convert fontname to unibyte for match. */
encoded_font_name = string_make_unibyte (build_string (fontname));
font_name_copy = SDATA (encoded_font_name);
ptr = regex;
*ptr++ = '^';

View file

@ -1209,7 +1209,6 @@ w32_text_out (s, x, y,chars,nchars)
}
static void x_set_glyph_string_clipping P_ ((struct glyph_string *));
static void x_set_glyph_string_gc P_ ((struct glyph_string *));
static void x_draw_glyph_string_background P_ ((struct glyph_string *,
@ -2061,7 +2060,6 @@ x_draw_image_foreground (s)
}
/* Draw a relief around the image glyph string S. */
static void
@ -2812,14 +2810,6 @@ x_new_focus_frame (dpyinfo, frame)
if (old_focus && old_focus->auto_lower)
x_lower_frame (old_focus);
if (dpyinfo->w32_focus_frame && dpyinfo->w32_focus_frame->auto_raise)
pending_autoraise_frame = dpyinfo->w32_focus_frame;
else
@ -4688,7 +4678,6 @@ w32_read_socket (sd, expected, hold_quit)
if (f)
x_new_focus_frame (dpyinfo, f);
dpyinfo->grabbed = 0;
check_visibility = 1;
break;
@ -4906,7 +4895,6 @@ w32_read_socket (sd, expected, hold_quit)
}
/***********************************************************************
Text Cursor

View file

@ -3216,10 +3216,13 @@ display_buffer_1 (window)
}
DEFUN ("special-display-p", Fspecial_display_p, Sspecial_display_p, 1, 1, 0,
doc: /* Returns non-nil if a buffer named BUFFER-NAME would be created specially.
The value is actually t if the frame should be called with default frame
parameters, and a list of frame parameters if they were specified.
See `special-display-buffer-names', and `special-display-regexps'. */)
doc: /* Returns non-nil if a buffer named BUFFER-NAME gets a special frame.
If the value is t, a frame would be created for that buffer
using the default frame parameters. If the value is a list,
it is a list of frame parameters that would be used
to make a frame for that buffer.
The variables `special-display-buffer-names'
and `special-display-regexps' control this. */)
(buffer_name)
Lisp_Object buffer_name;
{

View file

@ -9521,11 +9521,13 @@ update_overlay_arrows (up_to_date)
}
/* Return overlay arrow string at row, or nil. */
/* Return overlay arrow string to display at row.
Return t if display as bitmap in left fringe.
Return nil if no overlay arrow. */
static Lisp_Object
overlay_arrow_at_row (f, row, pbitmap)
struct frame *f;
overlay_arrow_at_row (it, row, pbitmap)
struct it *it;
struct glyph_row *row;
int *pbitmap;
{
@ -9548,9 +9550,10 @@ overlay_arrow_at_row (f, row, pbitmap)
&& (MATRIX_ROW_START_CHARPOS (row) == marker_position (val)))
{
val = overlay_arrow_string_or_property (var, pbitmap);
if (FRAME_WINDOW_P (f))
if (FRAME_WINDOW_P (it->f)
&& WINDOW_LEFT_FRINGE_WIDTH (it->w) > 0)
return Qt;
else if (STRINGP (val))
if (STRINGP (val))
return val;
break;
}
@ -14077,8 +14080,8 @@ usage: (trace-to-stderr STRING &rest OBJECTS) */)
Building Desired Matrix Rows
***********************************************************************/
/* Return a temporary glyph row holding the glyphs of an overlay
arrow. Only used for non-window-redisplay windows. */
/* Return a temporary glyph row holding the glyphs of an overlay arrow.
Used for non-window-redisplay windows, and for windows w/o left fringe. */
static struct glyph_row *
get_overlay_arrow_glyph_row (w, overlay_arrow_string)
@ -14957,11 +14960,11 @@ display_line (it)
better to let it be displayed like cursors under X. */
if (! overlay_arrow_seen
&& (overlay_arrow_string
= overlay_arrow_at_row (it->f, row, &overlay_arrow_bitmap),
= overlay_arrow_at_row (it, row, &overlay_arrow_bitmap),
!NILP (overlay_arrow_string)))
{
/* Overlay arrow in window redisplay is a fringe bitmap. */
if (!FRAME_WINDOW_P (it->f))
if (STRINGP (overlay_arrow_string))
{
struct glyph_row *arrow_row
= get_overlay_arrow_glyph_row (it->w, overlay_arrow_string);
@ -14986,10 +14989,12 @@ display_line (it)
row->used[TEXT_AREA] = p2 - row->glyphs[TEXT_AREA];
}
}
else
{
it->w->overlay_arrow_bitmap = overlay_arrow_bitmap;
row->overlay_arrow_p = 1;
}
overlay_arrow_seen = 1;
it->w->overlay_arrow_bitmap = overlay_arrow_bitmap;
row->overlay_arrow_p = 1;
}
/* Compute pixel dimensions of this line. */

View file

@ -21,8 +21,13 @@ Boston, MA 02111-1307, USA. */
#include <X11/Xlib.h>
#include <X11/cursorfont.h>
/* Include Xutil.h after keysym.h to work around a bug that prevents
correct recognition of AltGr key in some X versions. */
#include <X11/keysym.h>
#include <X11/Xutil.h>
#include <X11/Xatom.h>
#include <X11/Xresource.h>