diff options
| author | Gnus developers | 2010-10-11 22:27:28 +0000 |
|---|---|---|
| committer | Katsumi Yamaoka | 2010-10-11 22:27:28 +0000 |
| commit | 6b7df8d3dd960dc4d62ffa4eabcdb37043a1c9e2 (patch) | |
| tree | 65d7c544f56420899df91da947a68e6f7e325e38 /lisp | |
| parent | 6ec07c5ad9aa8b9292025e0f9ed820b678852896 (diff) | |
| download | emacs-6b7df8d3dd960dc4d62ffa4eabcdb37043a1c9e2.tar.gz emacs-6b7df8d3dd960dc4d62ffa4eabcdb37043a1c9e2.zip | |
Merge changes made in Gnus trunk.
shr.el (shr-tag-hr): Use shr-hr-line to specify which character to use to display hr lines.
shr.el (shr-max-columns): Do not change state to nil if we just inserting spaces.
sieve-manage.el (sieve-manage-open): Allow port names as well as port numbers.
shr.el (shr-current-column, shr-find-fill-point): New functions; start thinking about breaking CJVK text.
nnimap.el (nnimap-transform-split-mail): Not all articles have bodies. Protect against this.
shr.el (shr-insert): Fix up the white space only regexp.
nnimap.el (nnimap-request-rename-group): Select group read-only before renaming it.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/gnus/ChangeLog | 26 | ||||
| -rw-r--r-- | lisp/gnus/nnimap.el | 9 | ||||
| -rw-r--r-- | lisp/gnus/shr.el | 34 | ||||
| -rw-r--r-- | lisp/gnus/sieve-manage.el | 4 |
4 files changed, 65 insertions, 8 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index deb1414b0cf..b95fe32431a 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,5 +1,31 @@ | |||
| 1 | 2010-10-11 Lars Magne Ingebrigtsen <larsi@gnus.org> | 1 | 2010-10-11 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 2 | 2 | ||
| 3 | * nnimap.el (nnimap-request-rename-group): Select group read-only | ||
| 4 | before renaming it. | ||
| 5 | |||
| 6 | * shr.el (shr-insert): Fix up the white space only regexp. | ||
| 7 | |||
| 8 | * nnimap.el (nnimap-transform-split-mail): Not all articles have | ||
| 9 | bodies. Protect against this. Reported by Michael Welsh Duggan. | ||
| 10 | |||
| 11 | * shr.el (shr-current-column): New function. | ||
| 12 | (shr-find-fill-point): New function. | ||
| 13 | |||
| 14 | 2010-10-11 Michael Welsh Duggan <md5i@md5i.com> (tiny change) | ||
| 15 | |||
| 16 | * sieve-manage.el (sieve-manage-open): Allow port names as well as port | ||
| 17 | numbers. | ||
| 18 | |||
| 19 | 2010-10-11 Julien Danjou <julien@danjou.info> | ||
| 20 | |||
| 21 | * shr.el (shr-hr-line): Add. | ||
| 22 | (shr-tag-hr): Use shr-hr-line to specify which character to use to | ||
| 23 | display hr lines. | ||
| 24 | (shr-max-columns): Do not change state to nil if we just inserting | ||
| 25 | spaces. | ||
| 26 | |||
| 27 | 2010-10-11 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 28 | |||
| 3 | * gnus-topic.el (gnus-topic-read-group): If after the last group, | 29 | * gnus-topic.el (gnus-topic-read-group): If after the last group, |
| 4 | select the last group. | 30 | select the last group. |
| 5 | 31 | ||
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el index 73b7fbdb733..4c05fb47a40 100644 --- a/lisp/gnus/nnimap.el +++ b/lisp/gnus/nnimap.el | |||
| @@ -667,6 +667,9 @@ textual parts.") | |||
| 667 | (deffoo nnimap-request-rename-group (group new-name &optional server) | 667 | (deffoo nnimap-request-rename-group (group new-name &optional server) |
| 668 | (when (nnimap-possibly-change-group nil server) | 668 | (when (nnimap-possibly-change-group nil server) |
| 669 | (with-current-buffer (nnimap-buffer) | 669 | (with-current-buffer (nnimap-buffer) |
| 670 | ;; Make sure we don't have this group open read/write. | ||
| 671 | (nnimap-command "EXAMINE %S" (utf7-encode group 7)) | ||
| 672 | (setf (nnimap-group nnimap-object) nil) | ||
| 670 | (car (nnimap-command "RENAME %S %S" | 673 | (car (nnimap-command "RENAME %S %S" |
| 671 | (utf7-encode group t) (utf7-encode new-name t)))))) | 674 | (utf7-encode group t) (utf7-encode new-name t)))))) |
| 672 | 675 | ||
| @@ -1627,8 +1630,10 @@ textual parts.") | |||
| 1627 | (forward-char (1+ bytes)) | 1630 | (forward-char (1+ bytes)) |
| 1628 | (setq bytes (nnimap-get-length)) | 1631 | (setq bytes (nnimap-get-length)) |
| 1629 | (delete-region (line-beginning-position) (line-end-position)) | 1632 | (delete-region (line-beginning-position) (line-end-position)) |
| 1630 | (forward-char (1+ bytes)) | 1633 | ;; There's a body; skip past that. |
| 1631 | (delete-region (line-beginning-position) (line-end-position)))))) | 1634 | (when bytes |
| 1635 | (forward-char (1+ bytes)) | ||
| 1636 | (delete-region (line-beginning-position) (line-end-position))))))) | ||
| 1632 | 1637 | ||
| 1633 | (defun nnimap-dummy-active-number (group &optional server) | 1638 | (defun nnimap-dummy-active-number (group &optional server) |
| 1634 | 1) | 1639 | 1) |
diff --git a/lisp/gnus/shr.el b/lisp/gnus/shr.el index 0700621a912..4031386368c 100644 --- a/lisp/gnus/shr.el +++ b/lisp/gnus/shr.el | |||
| @@ -59,7 +59,12 @@ fit these criteria." | |||
| 59 | :type 'char) | 59 | :type 'char) |
| 60 | 60 | ||
| 61 | (defcustom shr-table-corner ?+ | 61 | (defcustom shr-table-corner ?+ |
| 62 | "Charater used to draw table corner." | 62 | "Character used to draw table corner." |
| 63 | :group 'shr | ||
| 64 | :type 'char) | ||
| 65 | |||
| 66 | (defcustom shr-hr-line ?- | ||
| 67 | "Character used to draw hr line." | ||
| 63 | :group 'shr | 68 | :group 'shr |
| 64 | :type 'char) | 69 | :type 'char) |
| 65 | 70 | ||
| @@ -188,7 +193,8 @@ redirects somewhere else." | |||
| 188 | (shr-descend sub))))) | 193 | (shr-descend sub))))) |
| 189 | 194 | ||
| 190 | (defun shr-insert (text) | 195 | (defun shr-insert (text) |
| 191 | (when (eq shr-state 'image) | 196 | (when (and (eq shr-state 'image) |
| 197 | (not (string-match "\\`[ \t\n]+\\'" text))) | ||
| 192 | (insert "\n") | 198 | (insert "\n") |
| 193 | (setq shr-state nil)) | 199 | (setq shr-state nil)) |
| 194 | (cond | 200 | (cond |
| @@ -211,7 +217,7 @@ redirects somewhere else." | |||
| 211 | (unless shr-start | 217 | (unless shr-start |
| 212 | (setq shr-start (point))) | 218 | (setq shr-start (point))) |
| 213 | (insert elem) | 219 | (insert elem) |
| 214 | (when (> (current-column) shr-width) | 220 | (when (> (shr-current-column) shr-width) |
| 215 | (if (not (search-backward " " (line-beginning-position) t)) | 221 | (if (not (search-backward " " (line-beginning-position) t)) |
| 216 | (insert "\n") | 222 | (insert "\n") |
| 217 | (delete-char 1) | 223 | (delete-char 1) |
| @@ -224,6 +230,26 @@ redirects somewhere else." | |||
| 224 | (unless (string-match "[ \t\n]\\'" text) | 230 | (unless (string-match "[ \t\n]\\'" text) |
| 225 | (delete-char -1)))))) | 231 | (delete-char -1)))))) |
| 226 | 232 | ||
| 233 | (defun shr-find-fill-point () | ||
| 234 | (let ((found nil)) | ||
| 235 | (while (and (not found) | ||
| 236 | (not (bolp))) | ||
| 237 | (when (or (eq (preceding-char) ? ) | ||
| 238 | (aref fill-find-break-point-function-table (preceding-char))) | ||
| 239 | (setq found (point))) | ||
| 240 | (backward-char 1)) | ||
| 241 | (or found | ||
| 242 | (end-of-line)))) | ||
| 243 | |||
| 244 | (defun shr-current-column () | ||
| 245 | (let ((column 0)) | ||
| 246 | (save-excursion | ||
| 247 | (beginning-of-line) | ||
| 248 | (while (not (eolp)) | ||
| 249 | (incf column (char-width (following-char))) | ||
| 250 | (forward-char 1))) | ||
| 251 | column)) | ||
| 252 | |||
| 227 | (defun shr-ensure-newline () | 253 | (defun shr-ensure-newline () |
| 228 | (unless (zerop (current-column)) | 254 | (unless (zerop (current-column)) |
| 229 | (insert "\n"))) | 255 | (insert "\n"))) |
| @@ -468,7 +494,7 @@ Return a string with image data." | |||
| 468 | 494 | ||
| 469 | (defun shr-tag-hr (cont) | 495 | (defun shr-tag-hr (cont) |
| 470 | (shr-ensure-newline) | 496 | (shr-ensure-newline) |
| 471 | (insert (make-string shr-width ?-) "\n")) | 497 | (insert (make-string shr-width shr-hr-line) "\n")) |
| 472 | 498 | ||
| 473 | ;;; Table rendering algorithm. | 499 | ;;; Table rendering algorithm. |
| 474 | 500 | ||
diff --git a/lisp/gnus/sieve-manage.el b/lisp/gnus/sieve-manage.el index c542632a5a0..3d04a5a939f 100644 --- a/lisp/gnus/sieve-manage.el +++ b/lisp/gnus/sieve-manage.el | |||
| @@ -150,7 +150,7 @@ for doing the actual authentication." | |||
| 150 | :group 'sieve-manage) | 150 | :group 'sieve-manage) |
| 151 | 151 | ||
| 152 | (defcustom sieve-manage-default-port 2000 | 152 | (defcustom sieve-manage-default-port 2000 |
| 153 | "Default port number for managesieve protocol." | 153 | "Default port number or service name for managesieve protocol." |
| 154 | :type 'integer | 154 | :type 'integer |
| 155 | :group 'sieve-manage) | 155 | :group 'sieve-manage) |
| 156 | 156 | ||
| @@ -389,7 +389,7 @@ Optional argument AUTH indicates authenticator to use, see | |||
| 389 | If nil, chooses the best stream the server is capable of. | 389 | If nil, chooses the best stream the server is capable of. |
| 390 | Optional argument BUFFER is buffer (buffer, or string naming buffer) | 390 | Optional argument BUFFER is buffer (buffer, or string naming buffer) |
| 391 | to work in." | 391 | to work in." |
| 392 | (setq buffer (or buffer (format " *sieve* %s:%d" server (or port sieve-manage-default-port)))) | 392 | (setq buffer (or buffer (format " *sieve* %s:%s" server (or port sieve-manage-default-port)))) |
| 393 | (with-current-buffer (get-buffer-create buffer) | 393 | (with-current-buffer (get-buffer-create buffer) |
| 394 | (mapc 'make-local-variable sieve-manage-local-variables) | 394 | (mapc 'make-local-variable sieve-manage-local-variables) |
| 395 | (sieve-manage-disable-multibyte) | 395 | (sieve-manage-disable-multibyte) |