\f
;;; Compatibility:
;;
-;; This version of ffap supports Emacs 20 only, see the ftp site
-;; for a more general version. The following functions are necessary
-;; "leftovers" from the more general version.
+;; This version of ffap supports only the Emacs it is distributed in.
+;; See the ftp site for a more general version. The following
+;; functions are necessary "leftovers" from the more general version.
(defun ffap-mouse-event nil ; current mouse event, or nil
(and (listp last-nonmenu-event) last-nonmenu-event))
path)))
(defun ffap-locate-file (file &optional nosuffix path dir-ok)
- ;; The Emacs 20 version of locate-library could almost replace this,
+ ;; The current version of locate-library could almost replace this,
;; except it does not let us override the suffix list. The
;; compression-suffixes search moved to ffap-file-exists-string.
"A generic path-searching function, mimics `load' by default.
(abbreviate-file-name (expand-file-name guess))
))
(setq dir (file-name-directory guess))))
- (let ((minibuffer-completing-file-name t))
+ (let ((minibuffer-completing-file-name t)
+ (completion-ignore-case read-file-name-completion-ignore-case))
(setq guess
(completing-read
prompt
(defvar ffap-highlight t
"If non-nil, ffap highlights the current buffer substring.")
+(defface ffap
+ '((t :inherit highlight))
+ "Face used to highlight the current buffer substring."
+ :group 'ffap
+ :version "22.1")
+
(defvar ffap-highlight-overlay nil
"Overlay used by `ffap-highlight'.")
(t
(setq ffap-highlight-overlay
(apply 'make-overlay ffap-string-at-point-region))
- (overlay-put ffap-highlight-overlay 'face
- (if (facep 'ffap) 'ffap 'highlight)))))
+ (overlay-put ffap-highlight-overlay 'face 'ffap))))
\f
;;; Main Entrance (`find-file-at-point' == `ffap'):