emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/gnus/gnus-art.el


From: Miles Bader
Subject: [Emacs-diffs] Changes to emacs/lisp/gnus/gnus-art.el
Date: Mon, 25 Jul 2005 17:35:56 -0400

Index: emacs/lisp/gnus/gnus-art.el
diff -c emacs/lisp/gnus/gnus-art.el:1.85 emacs/lisp/gnus/gnus-art.el:1.86
*** emacs/lisp/gnus/gnus-art.el:1.85    Fri Jul 22 08:22:40 2005
--- emacs/lisp/gnus/gnus-art.el Mon Jul 25 21:35:55 2005
***************
*** 4117,4123 ****
                       ',gnus-newsgroup-ignored-charsets))
                  (mbl mml-buffer-list))
              (setq mml-buffer-list nil)
!             (insert-buffer gnus-original-article-buffer)
              (mime-to-mml ',handles)
              (setq gnus-article-mime-handles nil)
              (let ((mbl1 mml-buffer-list))
--- 4117,4123 ----
                       ',gnus-newsgroup-ignored-charsets))
                  (mbl mml-buffer-list))
              (setq mml-buffer-list nil)
!             (insert-buffer-substring gnus-original-article-buffer)
              (mime-to-mml ',handles)
              (setq gnus-article-mime-handles nil)
              (let ((mbl1 mml-buffer-list))
***************
*** 4199,4205 ****
                     ',gnus-newsgroup-ignored-charsets))
                (mbl mml-buffer-list))
            (setq mml-buffer-list nil)
!           (insert-buffer gnus-original-article-buffer)
            (mime-to-mml ',handles)
            (setq gnus-article-mime-handles nil)
            (let ((mbl1 mml-buffer-list))
--- 4199,4205 ----
                     ',gnus-newsgroup-ignored-charsets))
                (mbl mml-buffer-list))
            (setq mml-buffer-list nil)
!           (insert-buffer-substring gnus-original-article-buffer)
            (mime-to-mml ',handles)
            (setq gnus-article-mime-handles nil)
            (let ((mbl1 mml-buffer-list))
***************
*** 5160,5166 ****
  If end of article, return non-nil.  Otherwise return nil.
  Argument LINES specifies lines to be scrolled up."
    (interactive "p")
!   (gnus-end-of-window)
    (if (save-excursion
        (end-of-line)
        (and (pos-visible-in-window-p)  ;Not continuation line.
--- 5160,5166 ----
  If end of article, return non-nil.  Otherwise return nil.
  Argument LINES specifies lines to be scrolled up."
    (interactive "p")
!   (move-to-window-line -1)
    (if (save-excursion
        (end-of-line)
        (and (pos-visible-in-window-p)  ;Not continuation line.
***************
*** 5182,5187 ****
--- 5182,5201 ----
      (gnus-article-next-page-1 lines)
      nil))
  
+ (defmacro gnus-article-beginning-of-window ()
+   "Move point to the beginning of the window.
+ In Emacs, the point is placed at the line number which `scroll-margin'
+ specifies."
+   (if (featurep 'xemacs)
+       '(move-to-window-line 0)
+     '(move-to-window-line
+       (min (max 0 scroll-margin)
+          (max 1 (- (window-height)
+                    (if mode-line-format 1 0)
+                    (if (and (boundp 'header-line-format)
+                             (symbol-value 'header-line-format))
+                        1 0)))))))
+ 
  (defun gnus-article-next-page-1 (lines)
    (let ((scroll-in-place nil))
      (condition-case ()
***************
*** 5189,5201 ****
        (end-of-buffer
         ;; Long lines may cause an end-of-buffer error.
         (goto-char (point-max)))))
!   (gnus-beginning-of-window))
  
  (defun gnus-article-prev-page (&optional lines)
    "Show previous page of current article.
  Argument LINES specifies lines to be scrolled down."
    (interactive "p")
!   (gnus-beginning-of-window)
    (if (and gnus-page-broken
           (bobp)
           (not (save-restriction (widen) (bobp)))) ;Real beginning-of-buffer?
--- 5203,5215 ----
        (end-of-buffer
         ;; Long lines may cause an end-of-buffer error.
         (goto-char (point-max)))))
!   (gnus-article-beginning-of-window))
  
  (defun gnus-article-prev-page (&optional lines)
    "Show previous page of current article.
  Argument LINES specifies lines to be scrolled down."
    (interactive "p")
!   (move-to-window-line 0)
    (if (and gnus-page-broken
           (bobp)
           (not (save-restriction (widen) (bobp)))) ;Real beginning-of-buffer?
***************
*** 5209,5215 ****
              (scroll-down lines)
            (beginning-of-buffer
             (goto-char (point-min))))
!       (gnus-beginning-of-window)))))
  
  (defun gnus-article-only-boring-p ()
    "Decide whether there is only boring text remaining in the article.
--- 5223,5229 ----
              (scroll-down lines)
            (beginning-of-buffer
             (goto-char (point-min))))
!       (gnus-article-beginning-of-window)))))
  
  (defun gnus-article-only-boring-p ()
    "Decide whether there is only boring text remaining in the article.
***************
*** 5818,5824 ****
          (window-start (window-start)))
        (erase-buffer)
        (if (gnus-buffer-live-p gnus-original-article-buffer)
!         (insert-buffer gnus-original-article-buffer))
        (let ((winconf gnus-prev-winconf))
        (kill-all-local-variables)
        (gnus-article-mode)
--- 5832,5838 ----
          (window-start (window-start)))
        (erase-buffer)
        (if (gnus-buffer-live-p gnus-original-article-buffer)
!         (insert-buffer-substring gnus-original-article-buffer))
        (let ((winconf gnus-prev-winconf))
        (kill-all-local-variables)
        (gnus-article-mode)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]