1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
;;; mh-xemacs-compat.el --- GNU Emacs Functions needed by XEmacs
;; Copyright (C) 2001, 02, 2003 Free Software Foundation, Inc.
;; Author: FSF
;; Maintainer: Bill Wohler <wohler@newt.com>
;; Keywords: mail
;; See: mh-e.el
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING. If not, write to the
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
;;; Code:
;;; Some requires:
(require 'rfc822)
(eval-when-compile (require 'mh-utils))
;;; Simple compatibility:
(unless (fboundp 'match-string-no-properties)
(defsubst match-string-no-properties (match)
(buffer-substring-no-properties
(match-beginning match) (match-end match))))
(unless (fboundp 'line-beginning-position)
(defalias 'line-beginning-position 'point-at-bol))
(unless (fboundp 'line-end-position)
(defalias 'line-end-position 'point-at-eol))
(unless (fboundp 'timerp)
(defalias 'timerp 'itimerp))
(unless (fboundp 'cancel-timer)
(defalias 'cancel-timer 'delete-itimer))
;; Set up the modeline glyph
(defconst mh-modeline-logo
"/* XPM */
static char * file[] = {
\"18 13 2 1\",
\"# c #666699\",
\". c None s None\",
\"........##........\",
\".......####.......\",
\"......######......\",
\"......######......\",
\"....#########.....\",
\"..##############..\",
\".##...######....#.\",
\"##...#.#.####...#.\",
\"....#..#.##.#...#.\",
\"...#..##.#.#.#....\",
\"...#..#..#..#.#...\",
\"...#..#.##..#.##..\",
\"...#..#.#..#....#.\"};"
"The image for the modeline logo.")
(mh-do-in-xemacs
(defvar mh-modeline-glyph
(progn
(let* ((data mh-modeline-logo)
(glyph (make-glyph
(cond ((and (featurep 'xpm)
(device-on-window-system-p)
has-modeline-p)
`[xpm :data ,data])
(t [string :data "MH-E"])))))
(set-glyph-face glyph 'modeline-buffer-id)
glyph))
"Cute little logo to put in the modeline of MH-E buffers."))
(provide 'mh-xemacs-compat)
;;; Local Variables:
;;; indent-tabs-mode: nil
;;; sentence-end-double-space: nil
;;; End:
;;; mh-xemacs-compat.el ends here
|