Commit 2a36494c authored by Karoly Lorentey's avatar Karoly Lorentey
Browse files

Merged in changes from CVS HEAD

Patches applied:

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

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

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

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

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

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

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

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

 * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-41
   Make fringe-drawing stuff compile without a window-system

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

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

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

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

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

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

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

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

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


git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-59
parents e9cda827 e555f8d5
......@@ -14,6 +14,9 @@ so we will look at it and add it to the manual.
* Installation Changes in Emacs 21.4
---
** A Bulgarian translation of the Emacs Tutorial is available.
** You can build Emacs with Gtk+ widgets by specifying `--with-x-toolkit=gtk'
when you run configure. This requires Gtk+ 2.0 or newer. This port
provides a way to display multilingual text in menus (with some caveats).
......@@ -79,10 +82,32 @@ See the files mac/README and mac/INSTALL for build instructions.
---
** A French translation of the Emacs Tutorial is available.
** Building with -DENABLE_CHECKING does not automatically build with union
types any more. Add -DUSE_LISP_UNION_TYPE if you want union types.
* Changes in Emacs 21.4
** On window systems, lines which are exactly as wide as the window
(not counting the final newline character) are no longer broken into
two lines on the display (with just the newline on the second line).
Instead, the newline now "overflows" into the right fringe, and the
cursor will be displayed in the fringe when positioned on that newline.
The new user option 'overflow-newline-into-fringe' may be set to nil to
revert to the old behaviour of continuing such lines.
** The buffer boundaries (i.e. first and last line in the buffer) may now
be marked with bitmaps in the fringes. In addition, up and down
arrow bitmaps may be shown at the top and bottom of the right fringe
if the window can be scrolled in either direction.
This behavior is activated by setting the buffer-local variable
`indicate-buffer-boundaries' to a non-nil value. If value is t, both
boundaries and scrolling arrows are shown; any other non-nil value
shows only the buffer boundaries. The default value of this variable
is found in `default-indicate-buffer-boundaries'.
** New command `display-local-help' displays any local help at point
in the echo area. It is bound to `C-h .'. It normally displays the
same string that would be displayed on mouse-over using the
......@@ -1526,6 +1551,21 @@ use for the modifiers. For example, the following two lines swap
Meta and Alt:
(setq x-alt-keysym 'meta)
(setq x-meta-keysym 'alt)
+++
** vc-annotate-mode enhancements
In vc-annotate mode, you can now use the following key bindings for
enhanced functionality to browse the annotations of past revisions, or
to view diffs or log entries directly from vc-annotate-mode:
P: annotates the previous revision
N: annotates the next revision
J: annotates the revision at line
A: annotates the revision previous to line
D: shows the diff of the revision at line with its previous revision
L: shows the log of the revision at line
W: annotates the workfile (most up to date) version
* New modes and packages in 21.4
......@@ -1750,6 +1790,15 @@ configuration files.
* Lisp Changes in Emacs 21.4
+++
** New function `delete-dups' destructively removes `equal' duplicates
from a list. Of several `equal' occurrences of an element in the list,
the last one is kept.
+++
** `declare' is now a macro. This change was made mostly for
documentation purposes and should have no real effect on Lisp code.
** The new hook `before-save-hook' is invoked by `basic-save-buffer'
before saving buffers. This allows packages to perform various final
tasks, for example; it can be used by the copyright package to make
......
2004-01-22 Ognyan Kulev <ogi@fmi.uni-sofia.bg> (tiny change)
* quail/cyrillic.el ("bulgarian-phonetic"): Docstring fixed.
Duplicated entry removed.
("bulgarian-bds"): Docstring fixed.
2003-10-06 Dave Love <fx@gnu.org>
* quail/latin-ltx.el: Several additions.
......
......@@ -1169,12 +1169,15 @@ Unicode based."
The layout is similar to `cyrillic-translit', but all Bulgarian
characters are typed with a single key.
Use /& for ,A'(B (Cyrillic paragraph) and /# for $,1uV(B."
Use /& for ,A'(B (Cyrillic paragraph) and /# for $,1uV(B.
The letters $,1(G(B, $,1(H(B, $,1(I(B and $,1(N(B are not affected by Caps Lock."
nil t t t t nil nil nil nil nil t)
;; $,1(O(B $,1(2(B $,1(5(B $,1(@(B $,1(B(B $,1(J(B $,1(C(B $,1(8(B $,1(>(B $,1(?(B $,1(H(B $,1(I(B
;; $,1(0(B $,1(A(B $,1(4(B $,1(D(B $,1(3(B $,1(E(B $,1(9(B $,1(:(B $,1(;(B $,1(G(B
;; $,1(N(B $,1(7(B $,1(L(B $,1(F(B $,1(6(B $,1(1(B $,1(=(B $,1(<(B
;; $,1(G(B
;; $,1(O(B $,1(2(B $,1(5(B $,1(@(B $,1(B(B $,1(J(B $,1(C(B $,1(8(B $,1(>(B $,1(?(B $,1(H(B $,1(I(B
;; $,1(0(B $,1(A(B $,1(4(B $,1(D(B $,1(3(B $,1(E(B $,1(9(B $,1(:(B $,1(;(B $,1(N(B
;; $,1(7(B $,1(L(B $,1(F(B $,1(6(B $,1(1(B $,1(=(B $,1(<(B
(quail-define-rules
("/&" ?,A'(B)
......@@ -1238,7 +1241,6 @@ Use /& for ,A'(B (Cyrillic paragraph) and /# for $,1uV(B."
("y" ?$,1(j(B)
("x" ?$,1(l(B)
("\\" ?$,1(n(B)
("|" ?$,1(N(B)
("q" ?$,1(o(B))
;; Based on an implementation by Ognyan Kulev <ogi@fmi.uni-sofia.bg>.
......@@ -1248,13 +1250,18 @@ Use /& for ,A'(B (Cyrillic paragraph) and /# for $,1uV(B."
"bulgarian-bds" "Bulgarian" "$,1(1(4(A(B" nil
"Bulgarian standard keyboard layout (BDS)
This keyboard layout is standard for Bulgarian typewriters."
This keyboard layout is standard for Bulgarian typewriters.
The letters $,1(F(B, $,1(<(B, $,1(G(B, $,1(@(B, $,1(;(B, $,1(1(B and $,1(K(B are not affected by Caps Lock.
In addition to original bulgarian typewriter layout, keys \ and |
are transformed into ' and $,1(K(B respectively."
nil t t t t nil nil nil nil nil t)
;; 1! 2? 3+ 4" 5% 6= 7: 8/ 9_ 0$,1uV(B -I .V
;; ,$,1(k(B $,1(C(B $,1(5(B $,1(8(B $,1(H(B $,1(I(B $,1(:(B $,1(A(B $,1(4(B $,1(7(B $,1(F(B ;,A'(B
;; $,1(l(B $,1(O(B $,1(0(B $,1(>(B $,1(6(B $,1(3(B $,1(B(B $,1(=(B $,1(2(B $,1(<(B $,1(G(B ()
;; $,1(N(B $,1(9(B $,1(J(B $,1(M(B $,1(D(B $,1(E(B $,1(?(B $,1(@(B $,1(;(B $,1(1(B
;; () 1! 2? 3+ 4" 5% 6= 7: 8/ 9_ 0$,1uV(B -I .V
;; ,$,1(k(B $,1(C(B $,1(5(B $,1(8(B $,1(H(B $,1(I(B $,1(:(B $,1(A(B $,1(4(B $,1(7(B $,1(F(B ;,A'(B
;; $,1(l(B $,1(O(B $,1(0(B $,1(>(B $,1(6(B $,1(3(B $,1(B(B $,1(=(B $,1(2(B $,1(<(B $,1(G(B '$,1(K(B
;; $,1(N(B $,1(9(B $,1(J(B $,1(M(B $,1(D(B $,1(E(B $,1(?(B $,1(@(B $,1(;(B $,1(1(B
(quail-define-rules
......
/* Client process that communicates with GNU Emacs acting as server.
Copyright (C) 1986, 1987, 1994, 1999, 2000, 2001, 2003
Copyright (C) 1986, 1987, 1994, 1999, 2000, 2001, 2003, 2004
Free Software Foundation, Inc.
This file is part of GNU Emacs.
......@@ -438,9 +438,10 @@ main (argc, argv)
{
int sock_status = 0;
int default_sock = !socket_name;
int saved_errno = 0;
if (! socket_name)
if (default_sock)
{
socket_name = alloca (system_name_length + 100);
sprintf (socket_name, "/tmp/emacs%d-%s/server",
......@@ -459,7 +460,7 @@ main (argc, argv)
/* See if the socket exists, and if it's owned by us. */
sock_status = socket_status (server.sun_path);
saved_errno = errno;
if (sock_status)
if (sock_status && default_sock)
{
/* Failing that, see if LOGNAME or USER exist and differ from
our euid. If so, look for a socket based on the UID
......@@ -476,8 +477,18 @@ main (argc, argv)
if (pw && (pw->pw_uid != geteuid ()))
{
/* We're running under su, apparently. */
sprintf (server.sun_path, "/tmp/emacs%d-%s/server",
sprintf (socket_name, "/tmp/emacs%d-%s/server",
(int) pw->pw_uid, system_name);
if (strlen (socket_name) < sizeof (server.sun_path))
strcpy (server.sun_path, socket_name);
else
{
fprintf (stderr, "%s: socket-name %s too long",
argv[0], socket_name);
exit (1);
}
sock_status = socket_status (server.sun_path);
saved_errno = errno;
}
......
This diff is collapsed.
......@@ -341,7 +341,7 @@ displayed in a window:
;; get the first time off of the list
;; and calculate the number of minutes until the appointment.
(if appt-time-msg-list
(if (and appt-issue-message appt-time-msg-list)
(let ((appt-comp-time (car (car (car appt-time-msg-list)))))
(setq min-to-app (- appt-comp-time cur-comp-time))
......@@ -659,6 +659,10 @@ ARG is positive, otherwise off."
(appt-check t))))
;; This is needed for backwards compatibility. Feh.
(appt-activate 1)
(provide 'appt)
;;; arch-tag: bf5791c4-8921-499e-a26f-772b1788d347
......
......@@ -1118,7 +1118,7 @@ be used instead of a colon (:) to separate the hour and minute parts."
(if (equal ?a (downcase (aref s (match-beginning 2))))
0 1200)))
((string-match ; Hour and minute XX:XXam or XX:XXpm
"\\`[ \t\n\\^M]*\\([0-9]?[0-9]\\)[:.][\\([0-9][0-9]\\)\\([ap]\\)m\\>" s)
"\\`[ \t\n\\^M]*\\([0-9]?[0-9]\\)[:.]\\([0-9][0-9]\\)\\([ap]\\)m\\>" s)
(+ (* 100 (% (string-to-int
(substring s (match-beginning 1) (match-end 1)))
12))
......
......@@ -10,7 +10,7 @@
;;; This version incorporates changes up to version 2.10 of the
;;; Zawinski-Furuseth compiler.
(defconst byte-compile-version "$Revision: 2.139 $")
(defconst byte-compile-version "$Revision: 2.141 $")
;; This file is part of GNU Emacs.
......@@ -75,7 +75,7 @@
;; User customization variables:
;;
;; byte-compile-verbose Whether to report the function currently being
;; compiled in the minibuffer;
;; compiled in the echo area;
;; byte-optimize Whether to do optimizations; this may be
;; t, nil, 'source, or 'byte;
;; byte-optimize-log Whether to report (in excruciating detail)
......@@ -130,7 +130,7 @@
;; (baz 0))
;;
;; o It is possible to open-code a function in the same file it is defined
;; in without having to load that file before compiling it. the
;; in without having to load that file before compiling it. The
;; byte-compiler has been modified to remember function definitions in
;; the compilation environment in the same way that it remembers macro
;; definitions.
......@@ -1658,7 +1658,7 @@ The value is non-nil if there were no errors, nil if errors."
;;;###autoload
(defun compile-defun (&optional arg)
"Compile and evaluate the current top-level form.
Print the result in the minibuffer.
Print the result in the echo area.
With argument, insert value in current buffer after the form."
(interactive "P")
(save-excursion
......
......@@ -108,6 +108,10 @@ 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.")
(defun cl-cannot-unload ()
(error "Cannot unload the feature `cl'"))
;;; Predicates.
......@@ -579,9 +583,10 @@ Keywords supported: :test :test-not :key"
"Non-nil means don't make CL functions autoload.")
;;; Autoload the other portions of the package.
;; We want to replace the basic versions of dolist, dotimes below.
;; We want to replace the basic versions of dolist, dotimes, declare below.
(fmakunbound 'dolist)
(fmakunbound 'dotimes)
(fmakunbound 'declare)
(mapcar (function
(lambda (set)
(let ((file (if cl-fake-autoloads "<none>" (car set))))
......
......@@ -2429,7 +2429,7 @@ This makes the buffer visit that file, and marks it as not modified.
If you specify just a directory name as FILENAME, that means to use
the default file name but in that directory. You can also yank
the default file name into the minibuffer to edit it, using M-n.
the default file name into the minibuffer to edit it, using \\<minibuffer-local-map>\\[next-history-element].
If the buffer is not already visiting a file, the default file name
for the output file is the buffer name.
......
......@@ -454,7 +454,7 @@ If the charset is `composition', return the actual one."
(mm-mule-charset-to-mime-charset charset)))
(defun mm-delete-duplicates (list)
"Simple substitute for CL `delete-duplicates', testing with `equal'."
"Simple substitute for CL `delete-duplicates', testing with `equal'."
(let (result head)
(while list
(setq head (car list))
......
......@@ -476,11 +476,11 @@ Support for Russian using koi8-r and the russian-computer input method.")
(push elt ctext-non-standard-encodings-alist)))
(define-ccl-program ccl-encode-windows-1251-font
'(0
((r1 <<= 7)
(r1 += r2)
(translate-character encode-windows-1251 r0 r1)
)))
`(0
((if (r0 == ,(charset-id 'mule-unicode-0100-24ff))
((r1 <<= 7)
(r1 += r2)))
(translate-character encode-windows-1251 r0 r1))))
(add-to-list 'font-ccl-encoder-alist
'("microsoft-cp1251" . ccl-encode-windows-1251-font))
......
......@@ -137,8 +137,8 @@ is nil, raise an error."
;; Try to avoid losing badly when hooks installed in critical
;; places go away. (Some packages install things on
;; `kill-buffer-hook', `activate-menubar-hook' and the like.)
;; First off, provide a clean way for package `foo' to arrange
;; this by defining `foo-unload-hook'.
;; First off, provide a clean way for package FOO to arrange
;; this by adding hooks on the variable `FOO-unload-hook'.
(if unload-hook
(run-hooks unload-hook)
;; Otherwise, do our best. Look through the obarray for symbols
......
......@@ -79,6 +79,7 @@ we add the wrapper characters =?ISO-8859-1?Q?....?=."
(concat result (substring string i))))))
(defun mail-unquote-printable-hexdigit (char)
(setq char (upcase char))
(if (>= char ?A)
(+ (- char ?A) 10)
(- char ?0)))
......@@ -107,31 +108,41 @@ we expect to find and remove the wrapper characters =?ISO-8859-1?Q?....?=."
(apply 'concat (nreverse (cons (substring string i) strings))))))
;;;###autoload
(defun mail-unquote-printable-region (beg end &optional wrapper)
(defun mail-unquote-printable-region (beg end &optional wrapper noerror)
"Undo the \"quoted printable\" encoding in buffer from BEG to END.
If the optional argument WRAPPER is non-nil,
we expect to find and remove the wrapper characters =?ISO-8859-1?Q?....?=."
we expect to find and remove the wrapper characters =?ISO-8859-1?Q?....?=.
If NOERROR is non-nil, return t if successful."
(interactive "r\nP")
(save-match-data
(save-excursion
(save-restriction
(narrow-to-region beg end)
(goto-char (point-min))
(when (and wrapper
(looking-at "\\`=\\?ISO-8859-1\\?Q\\?\\([^?]*\\)\\?"))
(delete-region (match-end 1) end)
(delete-region (point) (match-beginning 1)))
(while (re-search-forward "=\\(..\\|\n\\)" nil t)
(goto-char (match-end 0))
(replace-match
(if (= (char-after (match-beginning 1)) ?\n)
""
(make-string 1
(+ (* 16 (mail-unquote-printable-hexdigit
(char-after (match-beginning 1))))
(mail-unquote-printable-hexdigit
(char-after (1+ (match-beginning 1)))))))
t t))))))
(let (failed)
(save-match-data
(save-excursion
(save-restriction
(narrow-to-region beg end)
(goto-char (point-min))
(when (and wrapper
(looking-at "\\`=\\?ISO-8859-1\\?Q\\?\\([^?]*\\)\\?"))
(delete-region (match-end 1) end)
(delete-region (point) (match-beginning 1)))
(while (re-search-forward "=\\(\\([0-9A-F][0-9A-F]\\)\\|[=\n]\\|..\\)" nil t)
(goto-char (match-end 0))
(cond ((= (char-after (match-beginning 1)) ?\n)
(replace-match ""))
((= (char-after (match-beginning 1)) ?=)
(replace-match "="))
((match-beginning 2)
(replace-match
(make-string 1
(+ (* 16 (mail-unquote-printable-hexdigit
(char-after (match-beginning 2))))
(mail-unquote-printable-hexdigit
(char-after (1+ (match-beginning 2))))))
t t))
(noerror
(setq failed t))
(t
(error "Malformed MIME quoted-printable message"))))
(not failed))))))
(eval-when-compile (require 'rfc822))
......
......@@ -84,6 +84,7 @@
"Spam filter for RMAIL, the mail reader for Emacs."
:group 'rmail)
;;;###autoload
(defcustom rmail-use-spam-filter nil
"*Non-nil to activate the rmail spam filter.
Specify `rmail-spam-definitions-alist' to define what you consider spam
......
......@@ -1364,6 +1364,7 @@ It returns t if it got any new messages."
(while all-files
(let ((opoint (point))
(new-messages 0)
(rsf-number-of-spam 0)
(delete-files ())
;; If buffer has not changed yet, and has not been saved yet,
;; don't replace the old backup file now.
......@@ -1446,11 +1447,59 @@ It returns t if it got any new messages."
(progn (goto-char opoint)
(if (or file-name rmail-inbox-list)
(message "(No new mail has arrived)")))
(if (rmail-summary-exists)
;; check new messages to see if any of them is spam:
(if rmail-use-spam-filter
(let*
((old-messages (- rmail-total-messages new-messages))
(rsf-scanned-message-number (1+ old-messages))
;; save deletion flags of old messages: vector starts
;; at zero (is one longer that no of messages),
;; therefore take 1+ old-messages
(save-deleted
(substring rmail-deleted-vector 0 (1+
old-messages))))
;; set all messages to undeleted
(setq rmail-deleted-vector
(make-string (1+ rmail-total-messages) ?\ ))
(while (<= rsf-scanned-message-number
rmail-total-messages)
(progn
(if (not (rmail-spam-filter rsf-scanned-message-number))
(progn (setq rsf-number-of-spam (1+ rsf-number-of-spam)))
)
(setq rsf-scanned-message-number (1+ rsf-scanned-message-number))
))
(if (> rsf-number-of-spam 0)
(progn
(when (rmail-expunge-confirmed)
(rmail-only-expunge t))
))
(setq rmail-deleted-vector
(concat
save-deleted
(make-string (- rmail-total-messages old-messages)
?\ )))
))
(if (rmail-summary-exists)
(rmail-select-summary
(rmail-update-summary)))
(message "%d new message%s read"
new-messages (if (= 1 new-messages) "" "s"))
(message "%d new message%s read%s"
new-messages (if (= 1 new-messages) "" "s")
;; print out a message on number of spam messages found:
(if (and rmail-use-spam-filter (> rsf-number-of-spam 0))
(if (= 1 new-messages)
(format ", and found to be a spam message"
rsf-number-of-spam)
(if (> rsf-number-of-spam 1)
(format ", %d of which found to be spam messages"
rsf-number-of-spam)
(format ", one of which found to be a spam message"
rsf-number-of-spam)))
""))
(if (and rmail-use-spam-filter (> rsf-number-of-spam 0))
(progn (if rmail-spam-filter-beep (beep t))
(sleep-for rmail-spam-sleep-after-message)))
;; Move to the first new message
;; unless we have other unseen messages before it.
(rmail-show-message (rmail-first-unseen-message))
......@@ -1680,7 +1729,9 @@ It returns t if it got any new messages."
header-end t))))
(if quoted-printable-header-field-end
(save-excursion
(rmail-decode-quoted-printable header-end (point))
(unless
(mail-unquote-printable-region header-end (point) nil t)
(message "Malformed MIME quoted-printable message"))
;; Change "quoted-printable" to "8bit",
;; to reflect the decoding we just did.
(goto-char quoted-printable-header-field-end)
......@@ -1825,7 +1876,10 @@ It returns t if it got any new messages."
(setq count (1+ count))
(if quoted-printable-header-field-end
(save-excursion
(rmail-decode-quoted-printable header-end (point))
(unless
(mail-unquote-printable-region header-end (point) nil t)
(message "Malformed MIME quoted-printable message"))
;; Change "quoted-printable" to "8bit",
;; to reflect the decoding we just did.
(goto-char quoted-printable-header-field-end)
......@@ -1836,7 +1890,13 @@ It returns t if it got any new messages."
(when
(condition-case nil
(progn
(base64-decode-region (1+ header-end) (point))
(base64-decode-region
(1+ header-end)
(save-excursion
;; Prevent base64-decode-region
;; from removing newline characters.
(skip-chars-backward "\n\t ")
(point)))
t)
(error nil))
(goto-char header-end)
......@@ -1854,6 +1914,7 @@ It returns t if it got any new messages."
(goto-char (point-min))
(while (search-forward "\n\^_" nil t); single char
(replace-match "\n^_")))); 2 chars: "^" and "_"
(or (bolp) (newline)) ; in case we lost the final newline.
(insert ?\^_)
(setq last-coding-system-used nil)
(or rmail-enable-mime
......@@ -1887,45 +1948,6 @@ It returns t if it got any new messages."
(t (error "Cannot convert to babyl format")))))
count))
(defun rmail-hex-char-to-integer (character)
"Return CHARACTER's value interpreted as a hex digit."
(if (and (>= character ?0) (<= character ?9))
(- character ?0)
(let ((ch (logior character 32)))
(if (and (>= ch ?a) (<= ch ?f))
(- ch (- ?a 10))
(error "Invalid hex digit `%c'" ch)))))
(defun rmail-hex-string-to-integer (hex-string)
"Return decimal integer for HEX-STRING."
(let ((hex-num 0)
(index 0))
(while (< index (length hex-string))
(setq hex-num (+ (* hex-num 16)
(rmail-hex-char-to-integer (aref hex-string index))))
(setq index (1+ index)))
hex-num))
(defun rmail-decode-quoted-printable (from to)
"Decode Quoted-Printable in the region between FROM and TO."
(interactive "r")
(goto-char from)
(or (markerp to)
(setq to (copy-marker to)))
(while (search-forward "=" to t)
(cond ((eq (following-char) ?\n)
(delete-char -1)
(delete-char 1))
((looking-at "[0-9A-F][0-9A-F]")
(let ((byte (rmail-hex-string-to-integer
(buffer-substring (point) (+ 2 (point))))))
(delete-region (1- (point)) (+ 2 (point)))
(insert byte)))
((looking-at "=")
(delete-char 1))
(t
(message "Malformed MIME quoted-printable message")))))
;; Delete the "From ..." line, creating various other headers with
;; information from it if they don't already exist. Now puts the
;; original line into a mail-from: header line for debugging and for
......@@ -3033,7 +3055,7 @@ See also user-option `rmail-confirm-expunge'."
(funcall rmail-confirm-expunge
"Erase deleted messages from Rmail file? ")))
(defun rmail-only-expunge ()
(defun rmail-only-expunge (&optional dont-show)
"Actually erase all deleted messages in the file."
(interactive)
(set-buffer rmail-buffer)
......@@ -3112,11 +3134,12 @@ See also user-option `rmail-confirm-expunge'."
(message "Expunging deleted messages...done")
(if (not win)
(narrow-to-region (- (buffer-size) omin) (- (buffer-size) omax)))
(rmail-show-message
(if (zerop rmail-current-message) 1 nil))
(if rmail-enable-mime
(goto-char (+ (point-min) opoint))
(goto-char (+ (point) opoint))))))
(if (not dont-show)
(rmail-show-message
(if (zerop rmail-current-message) 1 nil)
(if rmail-enable-mime
(goto-char (+ (point-min) opoint))
(goto-char (+ (point) opoint))))))))
(defun rmail-expunge ()
"Erase deleted messages from Rmail file and summary buffer."
......
......@@ -680,13 +680,8 @@ This is relative to `smtpmail-queue-dir'.")
;; size estimate:
(+ (- (point-max) (point-min))
;; Add one byte for each change-of-line
;; because or CR-LF representation:
(count-lines (point-min) (point-max))
;; For some reason, an empty line is
;; added to the message. Maybe this
;; is a bug, but it can't hurt to add
;; those two bytes anyway:
2)))
;; because of CR-LF representation:
(count-lines (point-min) (point-max)))))
""))
(body-part
(if (member '8bitmime supported-extensions)
......@@ -858,31 +853,15 @@ This is relative to `smtpmail-queue-dir'.")
)
(defun smtpmail-send-data (process buffer)
(let
((data-continue t)
(sending-data nil)
this-line
this-line-end)
(let ((data-continue t) sending-data)
(with-current-buffer buffer