lpath.el: No need to bind bookmark-yank-point and
[gnus] / lisp / lpath.el
1 ;; Shut up.
2
3 (defun maybe-fbind (args)
4   (while args
5     (or (fboundp (car args))
6         (defalias (car args) 'ignore))
7     (setq args (cdr args))))
8
9 (defun maybe-bind (args)
10   (mapcar (lambda (var) (unless (boundp var) (set var nil))) args))
11
12 (unless (featurep 'xemacs)
13   (maybe-fbind '(pgg-display-output-buffer url-generic-parse-url))
14   (maybe-bind '(bookmark-current-buffer
15                 help-xref-stack-item url-version
16                 w3-meta-charset-content-type-regexp
17                 w3-meta-content-type-charset-regexp))
18
19   (when (<= emacs-major-version 22)
20     (defun ecomplete-add-item (type key text))
21     (defun ecomplete-save nil)
22     (defun hashcash-wait-async (&optional buffer))
23     (defun mail-add-payment (&optional arg async))
24     (defun mail-add-payment-async (&optional arg))
25     (defun netrc-get (alist type))
26     (defun netrc-machine (list machine &optional port defaultport))
27     (defun netrc-machine-user-or-password (mode authinfo-file-or-list machines
28                                                 ports defaults))
29     (defun netrc-parse (file))
30     (defun nnkiboze-score-file (a))
31     (maybe-fbind
32      '(Info-index
33        Info-index-next Info-menu bbdb-complete-name bookmark-default-handler
34        bookmark-get-bookmark-record bookmark-make-record-default
35        bookmark-prop-get display-time-event-handler epg-check-configuration
36        find-coding-system frame-device recenter-top-bottom
37        rmail-swap-buffers-maybe w3-do-setup w3-prepare-buffer w3-region
38        w32-focus-frame w3m-detect-meta-charset w3m-region))
39     (maybe-bind
40      '(w3m-link-map)))
41
42   (when (= emacs-major-version 21)
43     (defun canlock-insert-header (&optional id-for-key id-for-lock password))
44     (defun split-line (&optional arg))
45     (maybe-fbind
46      '(clear-string
47        coding-system-aliasee coding-system-from-name custom-autoload
48        delete-annotation delete-extent device-connection dfw-device
49        events-to-keys find-face font-lock-set-defaults get-char-table
50        glyph-height glyph-width help-buffer int-to-char ldap-search-entries
51        mail-aliases-setup make-annotation make-event make-glyph
52        make-network-process map-extents message-xmas-redefine put-char-table
53        run-mode-hooks set-extent-property set-itimer-function
54        set-keymap-default-binding temp-directory time-to-seconds ucs-to-char
55        unicode-precedence-list unicode-to-char url-generic-parse-url
56        url-http-file-exists-p valid-image-instantiator-format-p
57        vcard-pretty-print w3-coding-system-for-mime-charset window-pixel-height
58        window-pixel-width))
59     (maybe-bind
60      '(eudc-protocol
61        filladapt-mode help-echo-owns-message itimer-list ps-print-color-p
62        smtpmail-default-smtp-server w3-meta-charset-content-type-regexp
63        w3-meta-content-type-charset-regexp))))
64
65 (when (featurep 'xemacs)
66   (defun canlock-insert-header (&optional id-for-key id-for-lock password))
67   (defun ecomplete-add-item (type key text))
68   (defun ecomplete-save nil)
69   (defun hashcash-wait-async (&optional buffer))
70   (defun mail-add-payment (&optional arg async))
71   (defun mail-add-payment-async (&optional arg))
72   (defun netrc-get (alist type))
73   (defun netrc-machine (list machine &optional port defaultport))
74   (defun netrc-machine-user-or-password (mode authinfo-file-or-list machines
75                                               ports defaults))
76   (defun netrc-parse (file))
77   (defun nnkiboze-score-file (a))
78   (defun split-line (&optional arg))
79   (eval-after-load "rmail"
80     '(defun rmail-toggle-header (&optional arg)))
81   (maybe-fbind
82    '(bookmark-default-handler
83      bookmark-get-bookmark-record bookmark-make-record-default
84      bookmark-prop-get clear-string codepage-setup coding-system-from-name
85      cp-supported-codepages create-image delete-overlay detect-coding-string
86      display-time-event-handler epg-check-configuration event-click-count
87      event-end event-start find-coding-systems-for-charsets
88      find-coding-systems-region find-coding-systems-string find-image
89      float-time help-buffer image-size image-type-available-p insert-image
90      mail-abbrevs-setup make-mode-line-mouse-map make-network-process
91      mouse-minibuffer-check mouse-movement-p mouse-scroll-subr overlay-lists
92      pgg-display-output-buffer posn-point posn-window put-image read-event
93      recenter-top-bottom rmail-msg-restore-non-pruned-header
94      rmail-swap-buffers-maybe select-safe-coding-system sort-coding-systems
95      track-mouse ucs-to-char url-generic-parse-url url-http-file-exists-p
96      url-insert-file-contents vcard-pretty-print w3m-detect-meta-charset
97      w3m-region window-edges))
98   (maybe-bind
99    '(adaptive-fill-first-line-regexp
100      bookmark-current-buffer buffer-display-table
101      cursor-in-non-selected-windows default-enable-multibyte-characters
102      default-file-name-coding-system eudc-protocol filladapt-mode
103      gnus-agent-expire-current-dirs help-xref-stack-item idna-program
104      installation-directory line-spacing mark-active
105      mouse-selection-click-count mouse-selection-click-count-buffer
106      ps-print-color-p rmail-default-file rmail-default-rmail-file
107      rmail-insert-mime-forwarded-message-function show-trailing-whitespace
108      smtpmail-default-smtp-server temporary-file-directory tool-bar-mode
109      transient-mark-mode url-version w3-meta-charset-content-type-regexp
110      w3m-link-map w3-meta-content-type-charset-regexp))
111
112   (when (or (and (= emacs-major-version 21) (= emacs-minor-version 4))
113             (featurep 'sxemacs))
114     (maybe-fbind
115      '(custom-autoload
116        decode-char display-graphic-p display-images-p display-visual-class
117        get-display-table make-temp-file next-single-char-property-change
118        put-display-table select-frame-set-input-focus set-buffer-multibyte
119        string-as-multibyte timer-set-function unicode-precedence-list
120        unicode-to-char w32-focus-frame x-focus-frame))
121     (maybe-bind
122      '(scroll-margin
123        timer-list)))
124
125   (when (and (= emacs-major-version 21) (= emacs-minor-version 4))
126     (maybe-fbind
127      '(propertize)))
128
129   (unless (featurep 'mule)
130     (maybe-fbind
131      '(ccl-execute-on-string
132        char-charset charsetp coding-system-get find-charset-region
133        get-charset-property pgg-display-output-buffer pgg-parse-crc24-string
134        unicode-precedence-list))
135     (maybe-bind
136      '(current-language-environment
137        language-info-alist pgg-parse-crc24)))
138
139   (unless (featurep 'file-coding)
140     (maybe-fbind
141      '(coding-system-aliasee
142        coding-system-base coding-system-change-eol-conversion coding-system-list
143        coding-system-p decode-coding-region decode-coding-string
144        detect-coding-region encode-coding-region encode-coding-string
145        find-coding-system))
146     (maybe-bind
147      '(buffer-file-coding-system
148        coding-system-for-read coding-system-for-write
149        enable-multibyte-characters file-name-coding-system))))
150
151 (provide 'lpath)
152
153 ;;; arch-tag: d1ad864f-dca6-4d21-aa3f-be3248e66dba