Mercurial > hg > xemacs-beta
diff lisp/gnus/gnus-art.el @ 122:d2f30a177268 r20-1b14
Import from CVS: tag r20-1b14
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:26:03 +0200 |
parents | cca96a509cfe |
children | 9b50b4588a93 |
line wrap: on
line diff
--- a/lisp/gnus/gnus-art.el Mon Aug 13 09:25:31 2007 +0200 +++ b/lisp/gnus/gnus-art.el Mon Aug 13 09:26:03 2007 +0200 @@ -744,26 +744,27 @@ (interactive) (save-excursion (goto-char (point-min)) - (re-search-forward "\n\n") - (let ((buffer-read-only nil)) - (while (search-forward "\b" nil t) - (let ((next (following-char)) - (previous (char-after (- (point) 2)))) - ;; We do the boldification/underlining by hiding the - ;; overstrikes and putting the proper text property - ;; on the letters. - (cond - ((eq next previous) - (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike) - (put-text-property (point) (1+ (point)) 'face 'bold)) - ((eq next ?_) - (gnus-article-hide-text-type (1- (point)) (1+ (point)) 'overstrike) - (put-text-property - (- (point) 2) (1- (point)) 'face 'underline)) - ((eq previous ?_) - (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike) - (put-text-property - (point) (1+ (point)) 'face 'underline)))))))) + (when (search-forward "\n\n" nil t) + (let ((buffer-read-only nil)) + (while (search-forward "\b" nil t) + (let ((next (following-char)) + (previous (char-after (- (point) 2)))) + ;; We do the boldification/underlining by hiding the + ;; overstrikes and putting the proper text property + ;; on the letters. + (cond + ((eq next previous) + (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike) + (put-text-property (point) (1+ (point)) 'face 'bold)) + ((eq next ?_) + (gnus-article-hide-text-type + (1- (point)) (1+ (point)) 'overstrike) + (put-text-property + (- (point) 2) (1- (point)) 'face 'underline)) + ((eq previous ?_) + (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike) + (put-text-property + (point) (1+ (point)) 'face 'underline))))))))) (defun article-fill () "Format too long lines." @@ -2142,8 +2143,10 @@ (defun gnus-article-show-summary () "Reconfigure windows to show summary buffer." (interactive) - (gnus-configure-windows 'article) - (gnus-summary-goto-subject gnus-current-article)) + (if (not (gnus-buffer-live-p gnus-summary-buffer)) + (error "There is no summary buffer for this article buffer") + (gnus-configure-windows 'article) + (gnus-summary-goto-subject gnus-current-article))) (defun gnus-article-describe-briefly () "Describe article mode commands briefly."