+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
',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))
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.
(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 ()
(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?
(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.
(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
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