Using saved parent location: http://bzr.savannah.gnu.org/r/emacs/trunk/ Now on revision 102015. ------------------------------------------------------------ revno: 102015 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-10-19 20:55:30 -0700 message: * make-dist: No longer create lisp/MANIFEST. No-one can remember what this file was for. http://lists.gnu.org/archive/html/emacs-devel/2010-10/msg00512.html diff: === modified file 'ChangeLog' --- ChangeLog 2010-10-14 14:32:27 +0000 +++ ChangeLog 2010-10-20 03:55:30 +0000 @@ -1,3 +1,7 @@ +2010-10-20 Glenn Morris + + * make-dist: No longer create lisp/MANIFEST. + 2010-10-14 Glenn Morris * BUGS, INSTALL.BZR, README: Updates. === modified file 'make-dist' --- make-dist 2010-10-13 03:17:59 +0000 +++ make-dist 2010-10-20 03:55:30 +0000 @@ -270,18 +270,6 @@ $EMACS -batch -f batch-byte-recompile-directory lisp leim fi -## What is this file for? It goes in srcdir, not the tarfile. -## Why does it exclude term/ ? -echo "Making lisp/MANIFEST" - -files=`find lisp -type f -name '*.el'` -for file in $files; do - case "$file" in - */subdirs.el|*/default.el|*/loaddefs.el|*/term/*) continue ;; - esac - sed -n 's/^;;; //p; q' $file -done | sort > lisp/MANIFEST - echo "Creating staging directory: \`${tempparent}'" mkdir ${tempparent} ------------------------------------------------------------ revno: 102014 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-10-19 20:53:34 -0700 message: Fix format of old lib-src/ChangeLog entry. diff: === modified file 'lib-src/ChangeLog' --- lib-src/ChangeLog 2010-10-10 15:35:04 +0000 +++ lib-src/ChangeLog 2010-10-20 03:53:34 +0000 @@ -5376,10 +5376,10 @@ (main): Improve usage message. (error): Write to stderr, not stdout. - * b2m.c cvtmail.c digest-doc.c emacsclient.c emacsserver.c etags.c - fakemail.c hexl.c make-docfile.c profile.c sorted-doc.c test-distrib.c - timer.c wakeup.c yow.c: Eliminate some -Wall warnings from unused - variables and implicitly declared functions. + * b2m.c, cvtmail.c, digest-doc.c, emacsclient.c, emacsserver.c: + * etags.c, fakemail.c, hexl.c, make-docfile.c, profile.c, sorted-doc.c: + * test-distrib.c, timer.c, wakeup.c, yow.c: Eliminate some -Wall + warnings from unused variables and implicitly declared functions. 1994-10-11 Richard Stallman ------------------------------------------------------------ revno: 102013 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-10-19 20:52:27 -0700 message: Fix src/Makefile.in comment typo from r101897. diff: === modified file 'src/Makefile.in' --- src/Makefile.in 2010-10-15 07:46:47 +0000 +++ src/Makefile.in 2010-10-20 03:52:27 +0000 @@ -177,7 +177,7 @@ ## If !HAVE_X11 || USE_GTK, empty. ## Else if USE_X_TOOLKIT, $(lwlibdir)/liblw.a. -## Else $(oldxmenudir)/libXMenu11.a. +## Else $(oldXMenudir)/libXMenu11.a. ## (Actually, rather than being empty, it is set to "nothing". ## It is never actually used for anything in this case. ## This is done because there is a rule with target $(OLDXMENU) below, ------------------------------------------------------------ revno: 102012 committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-20 00:44:28 +0000 message: shr.el (shr-find-fill-point): Shorten line if the preceding char is kinsoku-eol regardless of shr-kinsoku-shorten. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-20 00:02:35 +0000 +++ lisp/gnus/ChangeLog 2010-10-20 00:44:28 +0000 @@ -1,3 +1,8 @@ +2010-10-20 Katsumi Yamaoka + + * shr.el (shr-find-fill-point): Shorten line if the preceding char is + kinsoku-eol regardless of shr-kinsoku-shorten. + 2010-10-19 Lars Magne Ingebrigtsen * shr.el (shr-find-fill-point): Don't leave blanks at the start of some === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-20 00:02:35 +0000 +++ lisp/gnus/shr.el 2010-10-20 00:44:28 +0000 @@ -272,13 +272,19 @@ ;; Don't put kinsoku-bol characters at the beginning of a line, ;; or kinsoku-eol characters at the end of a line, (let ((count 4)) - (if shr-kinsoku-shorten + (if (or shr-kinsoku-shorten + (and (aref (char-category-set (preceding-char)) ?<) + (progn + (setq count (1- count)) + (backward-char 1) + t))) (while (and - (> count 0) + (>= (setq count (1- count)) 0) + (not (memq (preceding-char) (list ?\C-@ ?\n ? ))) (or (aref (char-category-set (preceding-char)) ?<) (aref (char-category-set (following-char)) ?>))) (backward-char 1)) - (while (and (> count 0) + (while (and (>= (setq count (1- count)) 0) (aref (char-category-set (following-char)) ?>)) (forward-char 1))) (when (eq (following-char) ? ) ------------------------------------------------------------ revno: 102011 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-20 00:02:35 +0000 message: shr.el (shr-save-contents): New command and keystroke. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 23:26:28 +0000 +++ lisp/gnus/ChangeLog 2010-10-20 00:02:35 +0000 @@ -2,6 +2,7 @@ * shr.el (shr-find-fill-point): Don't leave blanks at the start of some lines. + (shr-save-contents): New command and keystroke. * nndoc.el (nndoc-type-alist): Add git support. (nndoc-git-type-p): New function. === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-19 23:26:28 +0000 +++ lisp/gnus/shr.el 2010-10-20 00:02:35 +0000 @@ -98,6 +98,7 @@ (define-key map "I" 'shr-insert-image) (define-key map "u" 'shr-copy-url) (define-key map "v" 'shr-browse-url) + (define-key map "o" 'shr-save-contents) (define-key map "\r" 'shr-browse-url) map)) @@ -323,6 +324,23 @@ (message "No link under point") (browse-url url)))) +(defun shr-save-contents (directory) + "Save the contents from URL in a file." + (interactive "DSave contents of URL to directory: ") + (let ((url (get-text-property (point) 'shr-url))) + (if (not url) + (message "No link under point") + (url-retrieve (shr-encode-url url) + 'shr-store-contents (list url directory))))) + +(defun shr-store-contents (status url directory) + (unless (plist-get status :error) + (when (or (search-forward "\n\n" nil t) + (search-forward "\r\n\r\n" nil t)) + (write-region (point) (point-max) + (expand-file-name (file-name-nondirectory url) + directory))))) + (defun shr-image-fetched (status buffer start end) (when (and (buffer-name buffer) (not (plist-get status :error))) ------------------------------------------------------------ revno: 102010 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 23:26:28 +0000 message: shr.el (shr-find-fill-point): Don't leave blanks at the start of some lines. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 23:06:50 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 23:26:28 +0000 @@ -1,5 +1,8 @@ 2010-10-19 Lars Magne Ingebrigtsen + * shr.el (shr-find-fill-point): Don't leave blanks at the start of some + lines. + * nndoc.el (nndoc-type-alist): Add git support. (nndoc-git-type-p): New function. (nndoc-transform-git-article): Ditto. === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-19 22:20:47 +0000 +++ lisp/gnus/shr.el 2010-10-19 23:26:28 +0000 @@ -241,8 +241,8 @@ (insert "\n")) (put-text-property (1- (point)) (point) 'shr-break t) ;; No space is needed at the beginning of a line. - (if (eq (following-char) ? ) - (delete-char 1))) + (when (eq (following-char) ? ) + (delete-char 1))) (when (> shr-indentation 0) (shr-indent)) (end-of-line)) @@ -280,6 +280,8 @@ (while (and (> count 0) (aref (char-category-set (following-char)) ?>)) (forward-char 1))) + (when (eq (following-char) ? ) + (forward-char 1)) t))))) (defun shr-ensure-newline () ------------------------------------------------------------ revno: 102009 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 23:06:50 +0000 message: nndoc.el (nndoc-transform-git-headers): Generate Subject headers. gnus.texi (Document Groups): Mention git. diff: === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2010-10-19 22:30:29 +0000 +++ doc/misc/ChangeLog 2010-10-19 23:06:50 +0000 @@ -2,6 +2,7 @@ * gnus.texi (Customizing the IMAP Connection): The port strings are strings. + (Document Groups): Mention git. 2010-10-18 Lars Magne Ingebrigtsen === modified file 'doc/misc/gnus.texi' --- doc/misc/gnus.texi 2010-10-19 22:20:47 +0000 +++ doc/misc/gnus.texi 2010-10-19 23:06:50 +0000 @@ -17969,6 +17969,10 @@ @item lanl-gov-announce Announcement messages from LANL Gov Announce. +@cindex git commit messages +@item git +@code{git} commit messages. + @cindex forwarded messages @item rfc822-forward A message forwarded according to RFC822. === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 22:20:47 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 23:06:50 +0000 @@ -4,6 +4,7 @@ (nndoc-git-type-p): New function. (nndoc-transform-git-article): Ditto. (nndoc-transform-git-headers): Ditto. + (nndoc-transform-git-headers): Generate Subject headers. * shr.el (shr-parse-style): New function. (shr-tag-span): Ditto. === modified file 'lisp/gnus/nndoc.el' --- lisp/gnus/nndoc.el 2010-10-19 22:20:47 +0000 +++ lisp/gnus/nndoc.el 2010-10-19 23:06:50 +0000 @@ -232,19 +232,22 @@ (while articles (when (setq entry (cdr (assq (setq article (pop articles)) nndoc-dissection-alist))) - (insert (format "221 %d Article retrieved.\n" article)) - (if nndoc-generate-head-function - (funcall nndoc-generate-head-function article) - (insert-buffer-substring - nndoc-current-buffer (car entry) (nth 1 entry))) - (goto-char (point-max)) - (unless (eq (char-after (1- (point))) ?\n) - (insert "\n")) - (insert (format "Lines: %d\n" (nth 4 entry))) - (insert ".\n"))) - - (when nndoc-header-transform-function - (funcall nndoc-header-transform-function)) + (let ((start (point))) + (insert (format "221 %d Article retrieved.\n" article)) + (if nndoc-generate-head-function + (funcall nndoc-generate-head-function article) + (insert-buffer-substring + nndoc-current-buffer (car entry) (nth 1 entry))) + (goto-char (point-max)) + (unless (eq (char-after (1- (point))) ?\n) + (insert "\n")) + (insert (format "Lines: %d\n" (nth 4 entry))) + (insert ".\n") + (when nndoc-header-transform-function + (save-excursion + (save-restriction + (narrow-to-region start (point)) + (funcall nndoc-header-transform-function entry))))))) (nnheader-fold-continuation-lines) 'headers))))) @@ -671,10 +674,19 @@ (when (re-search-forward "^Author: " nil t) (replace-match "From: " t t))) -(defun nndoc-transform-git-headers () +(defun nndoc-transform-git-headers (entry) (goto-char (point-min)) - (while (re-search-forward "^Author: " nil t) - (replace-match "From: " t t))) + (when (re-search-forward "^Author: " nil t) + (replace-match "From: " t t)) + (let (subject) + (with-current-buffer nndoc-current-buffer + (goto-char (car entry)) + (when (search-forward "\n\n" nil t) + (setq subject (buffer-substring (point) (line-end-position))))) + (when subject + (goto-char (point-min)) + (forward-line 1) + (insert (format "Subject: %s\n" subject))))) (defun nndoc-lanl-gov-announce-type-p () (when (let ((case-fold-search nil)) ------------------------------------------------------------ revno: 102008 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 22:30:29 +0000 message: Update. diff: === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2010-10-18 22:09:28 +0000 +++ doc/misc/ChangeLog 2010-10-19 22:30:29 +0000 @@ -1,3 +1,8 @@ +2010-10-19 Lars Magne Ingebrigtsen + + * gnus.texi (Customizing the IMAP Connection): The port strings are + strings. + 2010-10-18 Lars Magne Ingebrigtsen * gnus-coding.texi (Gnus Maintainance Guide): Update to mention Emacs ------------------------------------------------------------ revno: 102007 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 22:20:47 +0000 message: Merge changes made in Gnus trunk. gnus.texi (Customizing the IMAP Connection): The port strings are strings. nnmairix.el (nnmairix-summary-mode-hook): Move nnmairix's `$' command to `G G' to avoid collisions. shr.el (shr-parse-style, shr-tag-span): New functions. nndoc.el (nndoc-type-alist): Add git support. (nndoc-git-type-p, nndoc-transform-git-article, nndoc-transform-git-headers): New functions. diff: === modified file 'doc/misc/gnus.texi' --- doc/misc/gnus.texi 2010-10-10 00:15:21 +0000 +++ doc/misc/gnus.texi 2010-10-19 22:20:47 +0000 @@ -14872,7 +14872,7 @@ @item nnimap-server-port If the server uses a non-standard port, that can be specified here. A -typical port would be @samp{imap} or @samp{imaps}. +typical port would be @code{"imap"} or @code{"imaps"}. @item nnimap-stream How @code{nnimap} should connect to the server. Possible values are: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 08:19:45 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 22:20:47 +0000 @@ -1,3 +1,16 @@ +2010-10-19 Lars Magne Ingebrigtsen + + * nndoc.el (nndoc-type-alist): Add git support. + (nndoc-git-type-p): New function. + (nndoc-transform-git-article): Ditto. + (nndoc-transform-git-headers): Ditto. + + * shr.el (shr-parse-style): New function. + (shr-tag-span): Ditto. + + * nnmairix.el (nnmairix-summary-mode-hook): Move nnmairix's `$' command + to `G G' to avoid collisions. + 2010-10-19 Katsumi Yamaoka * shr.el: Load kinsoku if necessary. === modified file 'lisp/gnus/nndoc.el' --- lisp/gnus/nndoc.el 2010-10-08 23:55:33 +0000 +++ lisp/gnus/nndoc.el 2010-10-19 22:20:47 +0000 @@ -138,6 +138,14 @@ (generate-head-function . nndoc-generate-lanl-gov-head) (article-transform-function . nndoc-transform-lanl-gov-announce) (subtype preprints guess)) + (git + (file-begin . "\n- Log ---.*") + (article-begin . "^commit ") + (head-begin . "^Author: ") + (body-begin . "^$") + (file-end . "\n-----------------------------------------------------------------------") + (article-transform-function . nndoc-transform-git-article) + (header-transform-function . nndoc-transform-git-headers)) (rfc822-forward (article-begin . "^\n+") (body-end-function . nndoc-rfc822-forward-body-end-function) @@ -193,6 +201,7 @@ (defvoo nndoc-prepare-body-function nil) (defvoo nndoc-generate-head-function nil) (defvoo nndoc-article-transform-function nil) +(defvoo nndoc-header-transform-function nil) (defvoo nndoc-article-begin-function nil) (defvoo nndoc-generate-article-function nil) (defvoo nndoc-dissection-function nil) @@ -234,6 +243,8 @@ (insert (format "Lines: %d\n" (nth 4 entry))) (insert ".\n"))) + (when nndoc-header-transform-function + (funcall nndoc-header-transform-function)) (nnheader-fold-continuation-lines) 'headers))))) @@ -373,6 +384,7 @@ nndoc-file-end nndoc-article-begin nndoc-body-begin nndoc-body-end-function nndoc-body-end nndoc-prepare-body-function nndoc-article-transform-function + nndoc-header-transform-function nndoc-generate-head-function nndoc-body-begin-function nndoc-head-begin-function nndoc-generate-article-function @@ -649,6 +661,21 @@ (defun nndoc-slack-digest-type-p () 0) +(defun nndoc-git-type-p () + (and (search-forward "\n- Log ---" nil t) + (search-forward "\ncommit " nil t) + (search-forward "\nAuthor: " nil t))) + +(defun nndoc-transform-git-article (article) + (goto-char (point-min)) + (when (re-search-forward "^Author: " nil t) + (replace-match "From: " t t))) + +(defun nndoc-transform-git-headers () + (goto-char (point-min)) + (while (re-search-forward "^Author: " nil t) + (replace-match "From: " t t))) + (defun nndoc-lanl-gov-announce-type-p () (when (let ((case-fold-search nil)) (re-search-forward "^\\\\\\\\\n\\(Paper\\( (\\*cross-listing\\*)\\)?: [a-zA-Z-\\.]+/[0-9]+\\|arXiv:\\)" nil t)) === modified file 'lisp/gnus/nnmairix.el' --- lisp/gnus/nnmairix.el 2010-10-03 02:12:55 +0000 +++ lisp/gnus/nnmairix.el 2010-10-19 22:20:47 +0000 @@ -188,17 +188,17 @@ (defun nnmairix-summary-mode-hook () "Nnmairix summary mode keymap." (define-key gnus-summary-mode-map - (kbd "$ t") 'nnmairix-search-thread-this-article) - (define-key gnus-summary-mode-map - (kbd "$ f") 'nnmairix-search-from-this-article) - (define-key gnus-summary-mode-map - (kbd "$ m") 'nnmairix-widget-search-from-this-article) - (define-key gnus-summary-mode-map - (kbd "$ g") 'nnmairix-create-search-group-from-message) - (define-key gnus-summary-mode-map - (kbd "$ o") 'nnmairix-goto-original-article) - (define-key gnus-summary-mode-map - (kbd "$ u") 'nnmairix-remove-tick-mark-original-article)) + (kbd "G G t") 'nnmairix-search-thread-this-article) + (define-key gnus-summary-mode-map + (kbd "G G f") 'nnmairix-search-from-this-article) + (define-key gnus-summary-mode-map + (kbd "G G m") 'nnmairix-widget-search-from-this-article) + (define-key gnus-summary-mode-map + (kbd "G G g") 'nnmairix-create-search-group-from-message) + (define-key gnus-summary-mode-map + (kbd "G G o") 'nnmairix-goto-original-article) + (define-key gnus-summary-mode-map + (kbd "G G u") 'nnmairix-remove-tick-mark-original-article)) (add-hook 'gnus-group-mode-hook 'nnmairix-group-mode-hook) (add-hook 'gnus-summary-mode-hook 'nnmairix-summary-mode-hook) === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-19 08:19:45 +0000 +++ lisp/gnus/shr.el 2010-10-19 22:20:47 +0000 @@ -410,6 +410,29 @@ (defun shr-tag-s (cont) (shr-fontize-cont cont 'strike-through)) +(defun shr-tag-span (cont) + (let ((start (point)) + (color (cdr (assq 'color (shr-parse-style (cdr (assq :style cont))))))) + (shr-generic cont) + (when color + (let ((overlay (make-overlay start (point)))) + (overlay-put overlay 'face (cons 'foreground-color color)))))) + +(defun shr-parse-style (style) + (when style + (let ((plist nil)) + (dolist (elem (split-string style ";")) + (when elem + (setq elem (split-string elem ":")) + (when (and (car elem) + (cadr elem)) + (let ((name (replace-regexp-in-string "^ +\\| +$" "" (car elem))) + (value (replace-regexp-in-string "^ +\\| +$" "" (cadr elem)))) + (push (cons (intern name obarray) + value) + plist))))) + plist))) + (defun shr-tag-a (cont) (let ((url (cdr (assq :href cont))) (start (point)) ------------------------------------------------------------ revno: 102006 committer: Alan Mackenzie branch nick: trunk timestamp: Tue 2010-10-19 20:45:42 +0000 message: cc-langs.el (c-type-decl-prefix-key): C++ bit: move "\(const\|throw\|volatile\)\>" nearer the start of the regexp, so that these keywords aren't wrongly matched as identifiers. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 20:18:35 +0000 +++ lisp/ChangeLog 2010-10-19 20:45:42 +0000 @@ -1,5 +1,9 @@ 2010-10-19 Alan Mackenzie + * progmodes/cc-langs.el (c-type-decl-prefix-key): C++ bit: move + "\(const\|throw\|volatile\)\>" nearer the start of the regexp, so + that these keywords aren't wrongly matched as identifiers. + * progmodes/cc-mode.el (c-before-change, c-after-change): Move the setting of c-new-BEG and c-new-END from c-before-change to c-after-change. === modified file 'lisp/progmodes/cc-langs.el' --- lisp/progmodes/cc-langs.el 2010-10-09 19:58:28 +0000 +++ lisp/progmodes/cc-langs.el 2010-10-19 20:45:42 +0000 @@ -2676,15 +2676,15 @@ c++ (concat "\\(" "[*\(&]" "\\|" - (concat "\\(" ; 2 + (c-lang-const c-type-decl-prefix-key) + "\\|" + (concat "\\(" ; 3 ;; If this matches there's special treatment in ;; `c-font-lock-declarators' and ;; `c-font-lock-declarations' that check for a ;; complete name followed by ":: *". (c-lang-const c-identifier-start) "\\)") - "\\|" - (c-lang-const c-type-decl-prefix-key) "\\)" "\\([^=]\\|$\\)") pike "\\(\\*\\)\\([^=]\\|$\\)") ------------------------------------------------------------ revno: 102005 committer: Alan Mackenzie branch nick: trunk timestamp: Tue 2010-10-19 20:18:35 +0000 message: cc-mode.el (c-before-change, c-after-change): Move the setting of c-new-BEG and c-new-END from c-before-change to c-after-change. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 19:22:40 +0000 +++ lisp/ChangeLog 2010-10-19 20:18:35 +0000 @@ -1,3 +1,9 @@ +2010-10-19 Alan Mackenzie + + * progmodes/cc-mode.el (c-before-change, c-after-change): Move the + setting of c-new-BEG and c-new-END from c-before-change to + c-after-change. + 2010-10-19 Chong Yidong * cus-face.el (custom-theme-set-faces): Revert 2010-10-18 change. === modified file 'lisp/progmodes/cc-mode.el' --- lisp/progmodes/cc-mode.el 2010-10-03 01:53:04 +0000 +++ lisp/progmodes/cc-mode.el 2010-10-19 20:18:35 +0000 @@ -1029,10 +1029,6 @@ (buffer-substring-no-properties type-pos term-pos) (buffer-substring-no-properties beg end))))))) - ;; (c-new-BEG c-new-END) will be the region to fontify. It may become - ;; larger than (beg end). - (setq c-new-BEG beg - c-new-END end) (if c-get-state-before-change-functions (mapc (lambda (fn) (funcall fn beg end)) @@ -1086,6 +1082,10 @@ (when c-recognize-<>-arglists (c-after-change-check-<>-operators beg end)) + ;; (c-new-BEG c-new-END) will be the region to fontify. It may become + ;; larger than (beg end). + (setq c-new-BEG beg + c-new-END end) (if c-before-font-lock-function (save-excursion (funcall c-before-font-lock-function beg end old-len))))))) ------------------------------------------------------------ revno: 102004 committer: Chong Yidong branch nick: trunk timestamp: Tue 2010-10-19 15:24:39 -0400 message: etc/NEWS: Document change to mode-line-format. diff: === modified file 'etc/NEWS' --- etc/NEWS 2010-10-16 18:27:08 +0000 +++ etc/NEWS 2010-10-19 19:24:39 +0000 @@ -140,6 +140,8 @@ ** Lucid menus and dialogs can display antialiased fonts if Emacs is built with Xft. +** On graphical displays, the mode-line no longer ends in dashes. + ** Basic SELinux support has been added. This requires Emacs to be linked with libselinux at build time. ------------------------------------------------------------ revno: 102003 committer: Chong Yidong branch nick: trunk timestamp: Tue 2010-10-19 15:22:40 -0400 message: Revert 2010-10-18 change; use safe-functions instead. * cus-face.el (custom-theme-set-faces): Revert 2010-10-18 change. Don't mark as safe. * custom.el (custom-theme-set-variables): Likewise. (load-theme): Add custom-theme-set-faces and custom-theme-set-variables to safe-functions while loading. (custom-enabled-themes): Mark as risky. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 19:20:33 +0000 +++ lisp/ChangeLog 2010-10-19 19:22:40 +0000 @@ -1,3 +1,13 @@ +2010-10-19 Chong Yidong + + * cus-face.el (custom-theme-set-faces): Revert 2010-10-18 change. + Don't mark as safe. + + * custom.el (custom-theme-set-variables): Likewise. + (load-theme): Add custom-theme-set-faces and + custom-theme-set-variables to safe-functions while loading. + (custom-enabled-themes): Mark as risky. + 2010-10-18 Julien Danjou * bindings.el: Remove end dashes in default mode-line-format. === modified file 'lisp/cus-face.el' --- lisp/cus-face.el 2010-10-18 17:26:25 +0000 +++ lisp/cus-face.el 2010-10-19 19:22:40 +0000 @@ -349,8 +349,6 @@ (put face 'face-override-spec nil) (face-spec-set face spec t)))))))) -(put 'custom-theme-set-faces 'safe-function t) - ;; XEmacs compability function. In XEmacs, when you reset a Custom ;; Theme, you have to specify the theme to reset it to. We just apply ;; the next theme. === modified file 'lisp/custom.el' --- lisp/custom.el 2010-10-18 17:26:25 +0000 +++ lisp/custom.el 2010-10-19 19:22:40 +0000 @@ -993,8 +993,6 @@ (and (or now (default-boundp symbol)) (put symbol 'variable-comment comment))))))) -(put 'custom-theme-set-variables 'safe-function t) - ;;; Defining themes. @@ -1107,6 +1105,8 @@ (let ((custom-enabling-themes t)) (enable-theme 'user)))) +(defvar safe-functions) ; From unsafep.el + (defun load-theme (theme &optional no-enable) "Load a theme's settings from its file. Normally, this also enables the theme; use `disable-theme' to @@ -1135,7 +1135,11 @@ ;; Instead of simply loading the theme file, read it manually. (with-temp-buffer (insert-file-contents fn) + (require 'unsafep) (let ((custom--inhibit-theme-enable no-enable) + (safe-functions (append '(custom-theme-set-variables + custom-theme-set-faces) + safe-functions)) form scar) (while (setq form (let ((read-circle nil)) (condition-case nil @@ -1234,6 +1238,7 @@ :group 'customize :type '(repeat symbol) :set-after '(custom-theme-directory custom-theme-load-path) + :risky t :set (lambda (symbol themes) ;; Avoid an infinite loop when custom-enabled-themes is ;; defined in a theme (e.g. `user'). Enabling the theme sets ------------------------------------------------------------ revno: 102002 author: Julien Danjou committer: Chong Yidong branch nick: trunk timestamp: Tue 2010-10-19 15:20:33 -0400 message: Remove mode-line end dashes on graphical terminals. * tutorials/TUTORIAL: Don't mention mode-line end dashes. * bindings.el: Remove end dashes in default mode-line-format. diff: === modified file 'etc/ChangeLog' --- etc/ChangeLog 2010-10-16 18:27:08 +0000 +++ etc/ChangeLog 2010-10-19 19:20:33 +0000 @@ -1,3 +1,7 @@ +2010-10-19 Julien Danjou + + * tutorials/TUTORIAL: Don't mention mode-line end dashes. + 2010-10-16 Chong Yidong * themes: New directory for custom theme files, moved from lisp/. === modified file 'etc/tutorials/TUTORIAL' --- etc/tutorials/TUTORIAL 2010-01-13 08:35:10 +0000 +++ etc/tutorials/TUTORIAL 2010-10-19 19:20:33 +0000 @@ -498,12 +498,12 @@ you later decide that your changes were a mistake. If you look near the bottom of the screen you will see a line that -begins and ends with dashes, and starts with "--:--- TUTORIAL" or -something like that. This part of the screen normally shows the name -of the file that you are visiting. Right now, you are visiting a file -called "TUTORIAL" which is your personal scratch copy of the Emacs -tutorial. When you find a file with Emacs, that file's name will -appear in that precise spot. +begins with dashes, and starts with "--:--- TUTORIAL" or something +like that. This part of the screen normally shows the name of the +file that you are visiting. Right now, you are visiting a file called +"TUTORIAL" which is your personal scratch copy of the Emacs tutorial. +When you find a file with Emacs, that file's name will appear in that +precise spot. One special thing about the command for finding a file is that you have to say what file name you want. We say the command "reads an === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 15:43:27 +0000 +++ lisp/ChangeLog 2010-10-19 19:20:33 +0000 @@ -1,3 +1,7 @@ +2010-10-18 Julien Danjou + + * bindings.el: Remove end dashes in default mode-line-format. + 2010-10-19 Chong Yidong * bindings.el (global-map): Bind C-d to delete-char and deletechar === modified file 'lisp/bindings.el' --- lisp/bindings.el 2010-10-19 15:43:27 +0000 +++ lisp/bindings.el 2010-10-19 19:20:33 +0000 @@ -318,7 +318,7 @@ mouse-2: Make current window occupy the whole frame\n\ mouse-3: Remove current window from display") (recursive-edit-help-echo "Recursive edit, type C-M-c to get out") - (dashes (propertize "--" 'help-echo help-echo)) + (spaces (propertize " " 'help-echo help-echo)) (standard-mode-line-format (list "%e" @@ -334,9 +334,10 @@ '(vc-mode vc-mode) (propertize " " 'help-echo help-echo) 'mode-line-modes - `(which-func-mode ("" which-func-format ,dashes)) - `(global-mode-string ("" global-mode-string ,dashes)) - (propertize "-%-" 'help-echo help-echo))) + `(which-func-mode ("" which-func-format ,spaces)) + `(global-mode-string ("" global-mode-string ,spaces)) + `(:eval (unless (display-graphic-p) + ,(propertize "-%-" 'help-echo help-echo))))) (standard-mode-line-modes (list (propertize "%[" 'help-echo recursive-edit-help-echo) @@ -362,7 +363,7 @@ 'mouse-2 #'mode-line-widen)) (propertize ")" 'help-echo help-echo) (propertize "%]" 'help-echo recursive-edit-help-echo) - (propertize "--" 'help-echo help-echo))) + spaces)) (standard-mode-line-position `((-3 ,(propertize ------------------------------------------------------------ revno: 102001 committer: Chong Yidong branch nick: trunk timestamp: Tue 2010-10-19 11:43:27 -0400 message: Decouple C-d and delete, so that the former does not delete the region. * lisp/bindings.el (global-map): Bind C-d to delete-char and deletechar to delete-forward-char. * lisp/simple.el (normal-erase-is-backspace-mode): Remap delete to deletechar, and hence delete-forward-char. * src/cmds.c (Fdelete_char): Doc fix. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 11:44:07 +0000 +++ lisp/ChangeLog 2010-10-19 15:43:27 +0000 @@ -1,3 +1,11 @@ +2010-10-19 Chong Yidong + + * bindings.el (global-map): Bind C-d to delete-char and deletechar + to delete-forward-char. + + * simple.el (normal-erase-is-backspace-mode): Remap delete to + deletechar, and hence delete-forward-char. + 2010-10-19 Stefan Monnier * repeat.el (repeat): Use read-key (bug#6256). === modified file 'lisp/bindings.el' --- lisp/bindings.el 2010-08-29 16:17:13 +0000 +++ lisp/bindings.el 2010-10-19 15:43:27 +0000 @@ -824,7 +824,7 @@ (define-key global-map [?\C-\M--] 'negative-argument) (define-key global-map "\177" 'delete-backward-char) -(define-key global-map "\C-d" 'delete-forward-char) +(define-key global-map "\C-d" 'delete-char) (define-key global-map "\C-k" 'kill-line) (define-key global-map "\C-w" 'kill-region) @@ -933,7 +933,7 @@ ;; (define-key global-map [clearline] 'function-key-error) (define-key global-map [insertline] 'open-line) (define-key global-map [deleteline] 'kill-line) -(define-key global-map [deletechar] 'delete-char) +(define-key global-map [deletechar] 'delete-forward-char) ;; (define-key global-map [backtab] 'function-key-error) ;; (define-key global-map [f1] 'function-key-error) ;; (define-key global-map [f2] 'function-key-error) === modified file 'lisp/simple.el' --- lisp/simple.el 2010-10-14 14:32:27 +0000 +++ lisp/simple.el 2010-10-19 15:43:27 +0000 @@ -6628,7 +6628,7 @@ (if enabled (progn - (define-key local-function-key-map [delete] [?\C-d]) + (define-key local-function-key-map [delete] [deletechar]) (define-key local-function-key-map [kp-delete] [?\C-d]) (define-key local-function-key-map [backspace] [?\C-?]) (dolist (b bindings) === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-19 11:44:07 +0000 +++ src/ChangeLog 2010-10-19 15:43:27 +0000 @@ -1,3 +1,7 @@ +2010-10-19 Chong Yidong + + * cmds.c (Fdelete_char): Doc fix. + 2010-10-19 Ken Brown * s/cygwin.h (SIGNALS_VIA_CHARACTERS): New define (bug#7225). === modified file 'src/cmds.c' --- src/cmds.c 2010-09-24 17:48:10 +0000 +++ src/cmds.c 2010-10-19 15:43:27 +0000 @@ -230,7 +230,7 @@ Interactively, N is the prefix arg, and KILLFLAG is set if N was explicitly specified. -The command `delete-forward' is preferable for interactive use. */) +The command `delete-forward-char' is preferable for interactive use. */) (Lisp_Object n, Lisp_Object killflag) { EMACS_INT pos; ------------------------------------------------------------ revno: 102000 [merge] committer: Juanma Barranquero branch nick: trunk timestamp: Tue 2010-10-19 13:44:07 +0200 message: Merge changes from emacs-23 branch. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-19 09:50:07 +0000 +++ lisp/ChangeLog 2010-10-19 11:44:07 +0000 @@ -1,3 +1,22 @@ +2010-10-19 Stefan Monnier + + * repeat.el (repeat): Use read-key (bug#6256). + +2010-10-19 Chong Yidong + + * emacs-lisp/unsafep.el: Don't mark functions that display + messages as safe. Suggested by Johan Bockgård. + +2010-10-19 Stefan Monnier + + * minibuffer.el (completion--replace): Move point where it belongs + when there's a common suffix (bug#7215). + +2010-10-19 Kenichi Handa + + * international/characters.el: Add category '|' (word breakable) + to fullwidth characters. + 2010-10-19 Michael Albinus * net/tramp-sh.el (tramp-do-file-attributes-with-stat) === modified file 'lisp/emacs-lisp/regexp-opt.el' --- lisp/emacs-lisp/regexp-opt.el 2010-10-07 07:24:21 +0000 +++ lisp/emacs-lisp/regexp-opt.el 2010-10-19 11:44:07 +0000 @@ -141,11 +141,10 @@ (require 'cl)) (defun regexp-opt-group (strings &optional paren lax) - ;; Return a regexp to match a string in the sorted list STRINGS. - ;; If PAREN non-nil, output regexp parentheses around returned regexp. - ;; If LAX non-nil, don't output parentheses if it doesn't require them. - ;; Merges keywords to avoid backtracking in Emacs' regexp matcher. - + "Return a regexp to match a string in the sorted list STRINGS. +If PAREN non-nil, output regexp parentheses around returned regexp. +If LAX non-nil, don't output parentheses if it doesn't require them. +Merges keywords to avoid backtracking in Emacs' regexp matcher." ;; The basic idea is to find the shortest common prefix or suffix, remove it ;; and recurse. If there is no prefix, we divide the list into two so that ;; \(at least) one half will have at least a one-character common prefix. @@ -239,9 +238,7 @@ (defun regexp-opt-charset (chars) - ;; - ;; Return a regexp to match a character in CHARS. - ;; + "Return a regexp to match a character in CHARS." ;; The basic idea is to find character ranges. Also we take care in the ;; position of character set meta characters in the character set regexp. ;; === modified file 'lisp/emacs-lisp/unsafep.el' --- lisp/emacs-lisp/unsafep.el 2010-01-13 08:35:10 +0000 +++ lisp/emacs-lisp/unsafep.el 2010-10-18 17:28:20 +0000 @@ -101,15 +101,13 @@ (dolist (x '(;;Special forms and catch if or prog1 prog2 progn while unwind-protect ;;Safe subrs that have some side-effects - ding error message minibuffer-message random read-minibuffer - signal sleep-for string-match throw y-or-n-p yes-or-no-p + ding error random signal sleep-for string-match throw ;;Defsubst functions from subr.el caar cadr cdar cddr ;;Macros from subr.el - save-match-data unless when with-temp-message + save-match-data unless when ;;Functions from subr.el that have side effects - read-passwd split-string replace-regexp-in-string - play-sound-file)) + split-string replace-regexp-in-string play-sound-file)) (put x 'safe-function t)) ;;;###autoload === modified file 'lisp/international/characters.el' --- lisp/international/characters.el 2010-03-01 11:34:11 +0000 +++ lisp/international/characters.el 2010-10-15 00:41:53 +0000 @@ -188,6 +188,9 @@ cp932-2-byte)) (map-charset-chars #'modify-category-entry l ?j)) +;; Fullwidth characters +(modify-category-entry '(#xff01 . #xff60) ?\|) + ;; Unicode equivalents of JISX0201-kana (let ((range '(#xff61 . #xff9f))) (modify-category-entry range ?k) === modified file 'lisp/minibuffer.el' --- lisp/minibuffer.el 2010-10-08 10:14:47 +0000 +++ lisp/minibuffer.el 2010-10-19 11:44:07 +0000 @@ -508,10 +508,11 @@ (setq suffix-len (1+ suffix-len))) (unless (zerop suffix-len) (setq end (- end suffix-len)) - (setq newtext (substring newtext 0 (- suffix-len))))) - (goto-char beg) - (insert newtext) - (delete-region (point) (+ (point) (- end beg)))) + (setq newtext (substring newtext 0 (- suffix-len)))) + (goto-char beg) + (insert newtext) + (delete-region (point) (+ (point) (- end beg))) + (forward-char suffix-len))) (defcustom completion-cycle-threshold nil "Number of completion candidates below which cycling is used. === modified file 'lisp/repeat.el' --- lisp/repeat.el 2010-09-14 14:41:53 +0000 +++ lisp/repeat.el 2010-10-19 11:44:07 +0000 @@ -335,7 +335,7 @@ (setq real-last-command 'repeat) (setq repeat-undo-count 1) (unwind-protect - (while (let ((evt (read-event))) ;FIXME: read-key maybe? + (while (let ((evt (read-key))) ;; For clicks, we need to strip the meta-data to ;; check the underlying event name. (eq (or (car-safe evt) evt) === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-18 21:07:31 +0000 +++ src/ChangeLog 2010-10-19 11:44:07 +0000 @@ -1,3 +1,16 @@ +2010-10-19 Ken Brown + + * s/cygwin.h (SIGNALS_VIA_CHARACTERS): New define (bug#7225). + +2010-10-19 Kenichi Handa + + Fix incorrect font metrics when the same font is opened with + different pixelsizes. + + * xftfont.c: Include composite.h. + (xftfont_shape): New function. + (syms_of_xftfont): Set xftfont_driver.shape. + 2010-10-18 Julien Danjou * frame.c (Fframe_pointer_visible_p): === modified file 'src/s/cygwin.h' --- src/s/cygwin.h 2010-09-20 11:38:50 +0000 +++ src/s/cygwin.h 2010-10-19 11:44:07 +0000 @@ -101,5 +101,8 @@ returns ENOSYS. A workaround is to set G_SLICE=always-malloc. */ #define G_SLICE_ALWAYS_MALLOC +/* Send signals to subprocesses by "typing" special chars at them. */ +#define SIGNALS_VIA_CHARACTERS + /* arch-tag: 5ae7ba00-83b0-4ab3-806a-3e845779191b (do not change this comment) */ === modified file 'src/xftfont.c' --- src/xftfont.c 2010-08-05 23:34:12 +0000 +++ src/xftfont.c 2010-10-19 11:44:07 +0000 @@ -32,6 +32,7 @@ #include "blockinput.h" #include "character.h" #include "charset.h" +#include "composite.h" #include "fontset.h" #include "font.h" #include "ftfont.h" @@ -664,6 +665,23 @@ return len; } +Lisp_Object +xftfont_shape (Lisp_Object lgstring) +{ + struct font *font; + struct xftfont_info *xftfont_info; + FT_Face ft_face; + Lisp_Object val; + + CHECK_FONT_GET_OBJECT (LGSTRING_FONT (lgstring), font); + xftfont_info = (struct xftfont_info *) font; + ft_face = XftLockFace (xftfont_info->xftfont); + xftfont_info->ft_size = ft_face->size; + val = ftfont_driver.shape (lgstring); + XftUnlockFace (xftfont_info->xftfont); + return val; +} + static int xftfont_end_for_frame (FRAME_PTR f) { @@ -753,6 +771,9 @@ xftfont_driver.draw = xftfont_draw; xftfont_driver.end_for_frame = xftfont_end_for_frame; xftfont_driver.cached_font_ok = xftfont_cached_font_ok; +#if defined (HAVE_M17N_FLT) && defined (HAVE_LIBOTF) + xftfont_driver.shape = xftfont_shape; +#endif register_font_driver (&xftfont_driver, NULL); } ------------------------------------------------------------ revno: 101999 committer: Michael Albinus branch nick: trunk timestamp: Tue 2010-10-19 11:50:07 +0200 message: * net/tramp-sh.el (tramp-do-file-attributes-with-stat) (tramp-do-directory-files-and-attributes-with-stat): Use "e0" in order to make stat results a float. Patch by Andreas Schwab . diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-18 21:10:38 +0000 +++ lisp/ChangeLog 2010-10-19 09:50:07 +0000 @@ -1,3 +1,10 @@ +2010-10-19 Michael Albinus + + * net/tramp-sh.el (tramp-do-file-attributes-with-stat) + (tramp-do-directory-files-and-attributes-with-stat): Use "e0" in + order to make stat results a float. Patch by Andreas Schwab + . + 2010-10-18 Julien Danjou * avoid.el (mouse-avoidance-ignore-p): Ignore mouse when it is @@ -95,7 +102,8 @@ 2010-10-15 Michael Albinus * net/tramp-sh.el (tramp-open-connection-setup-interactive-shell): - Suppress expansion of tabs to spaces. + Suppress expansion of tabs to spaces. Reported by Dale Sedivec + . 2010-10-14 Kenichi Handa === modified file 'lisp/net/tramp-sh.el' --- lisp/net/tramp-sh.el 2010-10-15 12:07:38 +0000 +++ lisp/net/tramp-sh.el 2010-10-19 09:50:07 +0000 @@ -1241,7 +1241,7 @@ (format ;; On Opsware, pdksh (which is the true name of ksh there) doesn't ;; parse correctly the sequence "((". Therefore, we add a space. - "( (%s %s || %s -h %s) && %s -c '( (\"%%N\") %%h %s %s %%X.0 %%Y.0 %%Z.0 %%s.0 \"%%A\" t %%i.0 -1)' %s || echo nil)" + "( (%s %s || %s -h %s) && %s -c '( (\"%%N\") %%h %s %s %%Xe0 %%Ye0 %%Ze0 %%se0 \"%%A\" t %%ie0 -1)' %s || echo nil)" (tramp-get-file-exists-command vec) (tramp-shell-quote-argument localname) (tramp-get-test-command vec) @@ -1629,7 +1629,7 @@ ;; but it does not work on all remote systems. Therefore, we ;; quote the filenames via sed. "cd %s; echo \"(\"; (%s -a | sed -e s/\\$/\\\"/g -e s/^/\\\"/g | xargs " - "%s -c '(\"%%n\" (\"%%N\") %%h %s %s %%X.0 %%Y.0 %%Z.0 %%s.0 \"%%A\" t %%i.0 -1)'); " + "%s -c '(\"%%n\" (\"%%N\") %%h %s %s %%Xe0 %%Ye0 %%Ze0 %%se0 \"%%A\" t %%ie0 -1)'); " "echo \")\"") (tramp-shell-quote-argument localname) (tramp-get-ls-command vec) ------------------------------------------------------------ revno: 101998 committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 08:19:45 +0000 message: shr.el: Fix last change. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 07:57:50 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 08:19:45 +0000 @@ -1,6 +1,6 @@ 2010-10-19 Katsumi Yamaoka - * shr.el: Load kinsoku. + * shr.el: Load kinsoku if necessary. (shr-kinsoku-shorten): New internal variable. (shr-find-fill-point): Make kinsoku shorten text line if shr-kinsoku-shorten is bound to non-nil. === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-19 07:57:50 +0000 +++ lisp/gnus/shr.el 2010-10-19 08:19:45 +0000 @@ -32,7 +32,8 @@ (eval-when-compile (require 'cl)) (require 'browse-url) -(load "kinsoku" nil t) +(unless (aref (char-category-set (make-char 'japanese-jisx0208 33 35)) ?>) + (load "kinsoku" nil t)) (defgroup shr nil "Simple HTML Renderer" ------------------------------------------------------------ revno: 101997 committer: Katsumi Yamaoka branch nick: trunk timestamp: Tue 2010-10-19 07:57:50 +0000 message: shr.el: Improve kinsoku and table rendering. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-19 00:13:27 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 07:57:50 +0000 @@ -1,3 +1,15 @@ +2010-10-19 Katsumi Yamaoka + + * shr.el: Load kinsoku. + (shr-kinsoku-shorten): New internal variable. + (shr-find-fill-point): Make kinsoku shorten text line if + shr-kinsoku-shorten is bound to non-nil. + (shr-tag-table): Bild shr-kinsoku-shorten to t; refer to + shr-indentation too when testing if table is wider than frame width. + (shr-insert-table): Use `string-width' instead of `length' to measure + text width. + (shr-insert-table-ruler): Make sure indentation is done at bol. + 2010-10-19 Stefan Monnier * nnimap.el (nnimap-request-move-article, nnimap-parse-line) === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-18 05:45:06 +0000 +++ lisp/gnus/shr.el 2010-10-19 07:57:50 +0000 @@ -32,6 +32,7 @@ (eval-when-compile (require 'cl)) (require 'browse-url) +(load "kinsoku" nil t) (defgroup shr nil "Simple HTML Renderer" @@ -87,6 +88,7 @@ (defvar shr-inhibit-images nil) (defvar shr-list-mode nil) (defvar shr-content-cache nil) +(defvar shr-kinsoku-shorten nil) (defvar shr-map (let ((map (make-sparse-keymap))) @@ -247,36 +249,37 @@ (unless (string-match "[ \t\n]\\'" text) (delete-char -1))))) -(eval-and-compile (autoload 'kinsoku-longer "kinsoku")) - (defun shr-find-fill-point () - (let ((found nil)) - (while (and (not found) - (> (current-column) shr-indentation)) - (when (and (or (eq (preceding-char) ? ) - (aref fill-find-break-point-function-table - (preceding-char))) - (<= (current-column) shr-width)) - (setq found t)) - (backward-char 1) - (when (bolp) + (when (> (move-to-column shr-width) shr-width) + (backward-char 1)) + (let (failed) + (while (not + (or (setq failed (= (current-column) shr-indentation)) + (eq (preceding-char) ? ) + (eq (following-char) ? ) + (aref fill-find-break-point-function-table (preceding-char)))) + (backward-char 1)) + (if failed ;; There's no breakable point, so we give it up. - (end-of-line) - (while (aref fill-find-break-point-function-table - (preceding-char)) - (backward-char 1)) - (setq found 'failed))) - (cond ((eq found t) - ;; Don't put kinsoku-bol characters at the beginning of a line. - (or (eobp) - (kinsoku-longer) - (not (aref fill-find-break-point-function-table - (following-char))) - (forward-char 1))) - (found t) - (t - (end-of-line) - nil)))) + (progn + (end-of-line) + (while (aref fill-find-break-point-function-table (preceding-char)) + (backward-char 1)) + nil) + (or (eolp) + ;; Don't put kinsoku-bol characters at the beginning of a line, + ;; or kinsoku-eol characters at the end of a line, + (let ((count 4)) + (if shr-kinsoku-shorten + (while (and + (> count 0) + (or (aref (char-category-set (preceding-char)) ?<) + (aref (char-category-set (following-char)) ?>))) + (backward-char 1)) + (while (and (> count 0) + (aref (char-category-set (following-char)) ?>)) + (forward-char 1))) + t))))) (defun shr-ensure-newline () (unless (zerop (current-column)) @@ -545,6 +548,7 @@ (setq cont (or (cdr (assq 'tbody cont)) cont)) (let* ((shr-inhibit-images t) + (shr-kinsoku-shorten t) ;; Find all suggested widths. (columns (shr-column-specs cont)) ;; Compute how many characters wide each TD should be. @@ -555,8 +559,9 @@ (sketch (shr-make-table cont suggested-widths)) (sketch-widths (shr-table-widths sketch suggested-widths))) ;; This probably won't work very well. - (when (> (1+ (loop for width across sketch-widths - summing (1+ width))) + (when (> (+ (loop for width across sketch-widths + summing (1+ width)) + shr-indentation 1) (frame-width)) (setq truncate-lines t)) ;; Then render the table again with these new "hard" widths. @@ -607,12 +612,14 @@ ;; possibly. (dotimes (i (- height (length lines))) (end-of-line) - (insert (make-string (length (car lines)) ? ) "|") + (insert (make-string (string-width (car lines)) ? ) "|") (forward-line 1))))) (shr-insert-table-ruler widths))) (defun shr-insert-table-ruler (widths) - (shr-indent) + (when (and (bolp) + (> shr-indentation 0)) + (shr-indent)) (insert shr-table-corner) (dotimes (i (length widths)) (insert (make-string (aref widths i) shr-table-line) shr-table-corner)) ------------------------------------------------------------ revno: 101996 committer: Stefan Monnier branch nick: trunk timestamp: Mon 2010-10-18 20:13:27 -0400 message: * lisp/gnus/nnimap.el (nnimap-request-move-article, nnimap-parse-line) (nnimap-process-expiry-targets): Use unibyte for buffers that hold undecoded network data. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-18 23:41:03 +0000 +++ lisp/gnus/ChangeLog 2010-10-19 00:13:27 +0000 @@ -1,3 +1,9 @@ +2010-10-19 Stefan Monnier + + * nnimap.el (nnimap-request-move-article, nnimap-parse-line) + (nnimap-process-expiry-targets): Use unibyte for buffers that hold + undecoded network data. + 2010-10-18 Lars Magne Ingebrigtsen * gnus-agent.el (gnus-agent-toggle-plugged): Use the right minor mode @@ -20,9 +26,9 @@ 2010-10-18 Andrew Cohen - * gnus-registry.el (gnus-registry-split-fancy-with-parent): Splitting - according to references/in-reply-to obeys the ignore-groups variable, - while splitting by sender and subject do not. + * gnus-registry.el (gnus-registry-split-fancy-with-parent): + Splitting according to references/in-reply-to obeys the ignore-groups + variable, while splitting by sender and subject do not. 2010-10-18 Lars Magne Ingebrigtsen @@ -48,7 +54,7 @@ 2010-10-15 Andrew Cohen - * gnus-sum.el (gnus-summary-refer-thread): unconditionally ignore + * gnus-sum.el (gnus-summary-refer-thread): Unconditionally ignore duplicates. 2010-10-15 Kan-Ru Chen (tiny change) === modified file 'lisp/gnus/nnimap.el' --- lisp/gnus/nnimap.el 2010-10-18 22:09:28 +0000 +++ lisp/gnus/nnimap.el 2010-10-19 00:13:27 +0000 @@ -714,6 +714,7 @@ (deffoo nnimap-request-move-article (article group server accept-form &optional last internal-move-group) (with-temp-buffer + (mm-disable-multibyte) (when (nnimap-request-article article group server (current-buffer)) ;; If the move is internal (on the same server), just do it the easy ;; way. @@ -769,6 +770,7 @@ (dolist (article articles) (let ((target nnmail-expiry-target)) (with-temp-buffer + (mm-disable-multibyte) (when (nnimap-request-article article group server (current-buffer)) (nnheader-message 7 "Expiring article %s:%d" group article) (when (functionp target) @@ -1474,6 +1476,7 @@ (defun nnimap-parse-line (line) (let (char result) (with-temp-buffer + (mm-disable-multibyte) (insert line) (goto-char (point-min)) (while (not (eobp)) ------------------------------------------------------------ Use --include-merges or -n0 to see merged revisions.