Commit d8a88581 authored by Miles Bader's avatar Miles Bader
Browse files

Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-495

Merge from gnus--rel--5.10

Patches applied:

 * gnus--rel--5.10  (patch 95)

   - Update from CVS

2005-07-25  Katsumi Yamaoka  <yamaoka@jpl.org>

   * lisp/gnus/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-mime-save-part-and-strip): Use insert-buffer-substring
   instead of insert-buffer.
   (gnus-mime-delete-part): Ditto.
   (gnus-article-edit-exit): Ditto.

   * lisp/gnus/gnus-util.el (gnus-beginning-of-window): Remove.
   (gnus-end-of-window): Remove.

   * lisp/gnus/lpath.el: Don't bind scroll-margin.

2005-07-25  Simon Josefsson  <jas@extundo.com>

   * lisp/gnus/pgg.el (pgg-insert-url-with-w3): Don't load w3, it is possible
   to have the url package without w3.  Reported by Daiki Ueno
   <ueno@unixuser.org> and Luigi Panzeri <matley@muppetslab.org>.
parent 51db08eb
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-mime-save-part-and-strip): Use insert-buffer-substring
instead of insert-buffer.
(gnus-mime-delete-part): Ditto.
(gnus-article-edit-exit): Ditto.
* gnus-util.el (gnus-beginning-of-window): Remove.
(gnus-end-of-window): Remove.
* lpath.el: Don't bind scroll-margin.
2005-07-25 Simon Josefsson <jas@extundo.com>
* pgg.el (pgg-insert-url-with-w3): Don't load w3, it is possible
to have the url package without w3. Reported by Daiki Ueno
<ueno@unixuser.org> and Luigi Panzeri <matley@muppetslab.org>.
2005-07-21 Stefan Monnier <monnier@iro.umontreal.ca>
* mml.el (mml-minibuffer-read-disposition): Don't use inline by default
......
......@@ -4117,7 +4117,7 @@ Deleting parts may malfunction or destroy the article; continue? ")
',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))
......@@ -4199,7 +4199,7 @@ Deleting parts may malfunction or destroy the article; continue? ")
',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))
......@@ -5160,7 +5160,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.
......@@ -5182,6 +5182,20 @@ 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 (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,13 +5203,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?
......@@ -5209,7 +5223,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.
......@@ -5818,7 +5832,7 @@ groups."
(window-start (window-start)))
(erase-buffer)
(if (gnus-buffer-live-p gnus-original-article-buffer)
(insert-buffer gnus-original-article-buffer))
(insert-buffer-substring gnus-original-article-buffer))
(let ((winconf gnus-prev-winconf))
(kill-all-local-variables)
(gnus-article-mode)
......
......@@ -1577,30 +1577,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 (and (boundp 'header-line-format)
(symbol-value '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 (and (boundp 'header-line-format)
(symbol-value 'header-line-format))
1 0))))))))
(provide 'gnus-util)
;;; arch-tag: f94991af-d32b-4c97-8c26-ca12a934de49
......
......@@ -410,7 +410,6 @@ within the region."
(defun pgg-insert-url-with-w3 (url)
(ignore-errors
(require 'w3)
(require 'url)
(let (buffer-file-name)
(url-insert-file-contents url))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment