Synch to No Gnus 200507250934.
authoryamaoka <yamaoka>
Mon, 25 Jul 2005 09:34:49 +0000 (09:34 +0000)
committeryamaoka <yamaoka>
Mon, 25 Jul 2005 09:34:49 +0000 (09:34 +0000)
lisp/ChangeLog
lisp/gnus-art.el
lisp/gnus-util.el
lisp/lpath.el

index 536058d..6953769 100644 (file)
@@ -1,3 +1,18 @@
+2005-07-25  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+       * gnus-art.el (gnus-article-next-page): Revert.
+       (gnus-article-beginning-of-window): New macro.
+       (gnus-article-next-page-1): Use it.
+       (gnus-article-prev-page): Ditto.
+       (gnus-article-edit-part): Use insert-buffer-substring instead of
+       insert-buffer.
+       (gnus-article-edit-exit): Ditto.
+
+       * gnus-util.el (gnus-beginning-of-window): Remove.
+       (gnus-end-of-window): Remove.
+
+       * lpath.el: Don't bind header-line-format and scroll-margin.
+
 2005-07-25  Simon Josefsson  <jas@extundo.com>
 
        * pgg.el (pgg-insert-url-with-w3): Don't load w3, it is possible
index 761d88d..89e02a6 100644 (file)
@@ -4457,7 +4457,7 @@ and `gnus-mime-delete-part', and not provided at run-time normally."
                   ',gnus-newsgroup-ignored-charsets))
              (mbl mml-buffer-list))
          (setq mml-buffer-list nil)
-         (insert-buffer gnus-original-article-buffer)
+         (insert-buffer-substring gnus-original-article-buffer)
          (mime-to-mml ',handles)
          (setq gnus-article-mime-handles nil)
          (let ((mbl1 mml-buffer-list))
@@ -5516,7 +5516,7 @@ If given a numerical ARG, move forward ARG pages."
 If end of article, return non-nil.  Otherwise return nil.
 Argument LINES specifies lines to be scrolled up."
   (interactive "p")
-  (gnus-end-of-window)
+  (move-to-window-line -1)
   (if (save-excursion
        (end-of-line)
        (and (pos-visible-in-window-p)  ;Not continuation line.
@@ -5538,6 +5538,18 @@ Argument LINES specifies lines to be scrolled up."
     (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 header-line-format 1 0)))))))
+
 (defun gnus-article-next-page-1 (lines)
   (let ((scroll-in-place nil))
     (condition-case ()
@@ -5545,13 +5557,13 @@ Argument LINES specifies lines to be scrolled up."
       (end-of-buffer
        ;; Long lines may cause an end-of-buffer error.
        (goto-char (point-max)))))
-  (gnus-beginning-of-window))
+  (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")
-  (gnus-beginning-of-window)
+  (move-to-window-line 0)
   (if (and gnus-page-broken
           (bobp)
           (not (save-restriction (widen) (bobp)))) ;Real beginning-of-buffer?
@@ -5565,7 +5577,7 @@ Argument LINES specifies lines to be scrolled down."
              (scroll-down lines)
            (beginning-of-buffer
             (goto-char (point-min))))
-       (gnus-beginning-of-window)))))
+       (gnus-article-beginning-of-window)))))
 
 (defun gnus-article-only-boring-p ()
   "Decide whether there is only boring text remaining in the article.
index 7fc874c..4c1b32e 100644 (file)
@@ -1602,26 +1602,6 @@ empty directories from OLD-PATH."
   (defalias 'gnus-set-process-query-on-exit-flag
     'process-kill-without-query))
 
-(defun gnus-beginning-of-window ()
-  "Move point to the beginning of the window."
-  (move-to-window-line
-   (if (featurep 'xemacs)
-       0
-     (min scroll-margin
-         (max 1 (- (window-height)
-                   (if mode-line-format 1 0)
-                   (if header-line-format 1 0)))))))
-
-(defun gnus-end-of-window ()
-  "Move point to the end of the window."
-  (move-to-window-line
-   (if (featurep 'xemacs)
-       -1
-     (max (- -1 scroll-margin)
-         (- -1 (max 1 (- (window-height)
-                         (if mode-line-format 1 0)
-                         (if header-line-format 1 0))))))))
-
 (provide 'gnus-util)
 
 ;;; gnus-util.el ends here
index 86b8e5c..1daee79 100644 (file)
                    current-language-environment
                    default-enable-multibyte-characters
                    enable-multibyte-characters gnus-agent-expire-current-dirs
-                   header-line-format language-info-alist mark-active
-                   mouse-selection-click-count
+                   language-info-alist mark-active mouse-selection-click-count
                    mouse-selection-click-count-buffer pgg-parse-crc24
-                   scroll-margin temporary-file-directory
-                   transient-mark-mode)))
+                   temporary-file-directory transient-mark-mode)))
   (maybe-fbind '(bbdb-complete-name
                 delete-annotation delete-extent device-connection dfw-device
                 events-to-keys font-lock-set-defaults frame-device