From: morioka Date: Sat, 28 Feb 1998 17:25:38 +0000 (+0000) Subject: (gnus-bdf-image-file): New variable; moved from gnus.el. X-Git-Tag: gnus-6_7-tomo-199811302358~141 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1fc1b5f1e0b5efd2fb023cea719f031a2aa33469;p=elisp%2Fgnus.git- (gnus-bdf-image-file): New variable; moved from gnus.el. (gnus-mule-group-startup-message): New function; moved and renamed from `gnus-group-startup-message' of gnus.el. --- diff --git a/lisp/gnus-ems.el b/lisp/gnus-ems.el index d7e8fb8..02a2c61 100644 --- a/lisp/gnus-ems.el +++ b/lisp/gnus-ems.el @@ -2,6 +2,7 @@ ;; Copyright (C) 1995,96,97,98 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen +;; Tatsuya Ichikawa ;; Keywords: news ;; This file is part of GNU Emacs. @@ -78,6 +79,56 @@ (truncate-string valstr (, max-width)) valstr)))) +(defvar gnus-bdf-image-file nil) +(defun gnus-mule-group-startup-message (&optional x y) + "Insert startup message in current buffer." + ;; Insert the message. + (erase-buffer) + (insert + (if (featurep 'bitmap) + (format " %s + +" + "" (if (and (stringp gnus-bdf-image-file) + (file-exists-p gnus-bdf-image-file)) + (insert-file gnus-image-file))) + (format " %s + _ ___ _ _ + _ ___ __ ___ __ _ ___ + __ _ ___ __ ___ + _ ___ _ + _ _ __ _ + ___ __ _ + __ _ + _ _ _ + _ _ _ + _ _ _ + __ ___ + _ _ _ _ + _ _ + _ _ + _ _ + _ + __ + +" + ""))) + ;; And then hack it. + (gnus-indent-rigidly (point-min) (point-max) + (/ (max (- (window-width) (or x 46)) 0) 2)) + (goto-char (point-min)) + (forward-line 1) + (let* ((pheight (count-lines (point-min) (point-max))) + (wheight (window-height)) + (rest (- wheight pheight))) + (insert (make-string (max 0 (* 2 (/ rest 3))) ?\n))) + ;; Fontify some. + (put-text-property (point-min) (point-max) 'face 'gnus-splash-face) + (goto-char (point-min)) + (setq mode-line-buffer-identification (concat " " gnus-version)) + (setq gnus-simple-splash t) + (set-buffer-modified-p t)) + (defun gnus-encode-coding-string (string system) string) @@ -182,7 +233,11 @@ (fset 'gnus-summary-set-display-table (lambda ())) (fset 'gnus-encode-coding-string 'encode-coding-string) (fset 'gnus-decode-coding-string 'decode-coding-string) - + + (and window-system + (module-installed-p 'bitmap) + (fset 'gnus-group-startup-message 'gnus-mule-group-startup-message)) + (when (boundp 'gnus-check-before-posting) (setq gnus-check-before-posting (delq 'long-lines