From xemacs-m  Wed Apr 23 04:41:42 1997
Received: from marvin.enst.fr (tardieu@marvin.enst.fr [137.194.161.2])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id EAA24509
	for <xemacs-beta@xemacs.org>; Wed, 23 Apr 1997 04:41:39 -0500 (CDT)
Received: (from uucp@localhost)
	by marvin.enst.fr (8.8.5/8.8.5) with UUCP id LAA14273;
	Wed, 23 Apr 1997 11:34:31 +0200
Received: (from sam@localhost)
	by zaphod.enst.fr (8.8.4/8.8.5) id KAA02204;
	Wed, 23 Apr 1997 10:08:28 +0200
Sender: sam@ada.eu.org
To: xemacs-beta@xemacs.org
Cc: Rolf Ebert <re@waporo.muc.de>
Subject: [comp.emacs.xemacs,comp.lang.ada] Re: Ada mode find-file.el file
Mime-Version: 1.0 (generated by tm-edit 7.106)
Content-Type: multipart/mixed;
 boundary="Multipart_Wed_Apr_23_10:08:27_1997-1"
Content-Transfer-Encoding: 7bit
Date: 23 Apr 1997 10:08:27 +0200
Message-ID: <m33esii2kk.fsf@zaphod.enst.fr>
Lines: 165
X-Mailer: Gnus v5.4.15/XEmacs 20.1
From: Samuel Tardieu <sam@ada.eu.org>
Organization: Ada addicts (see http://ada.eu.org/)
Reply-To: Samuel Tardieu <sam@ada.eu.org>
Precedence: special-delivery
X-WWW: http://www-stud.enst.fr/~tardieu/
X-PGP-key: finger -l tardieu@cyclic.com
X-Mail-Processing: Sam's procmail tools

--Multipart_Wed_Apr_23_10:08:27_1997-1
Content-Type: text/plain; charset=US-ASCII

Is there a problem with Emacs' find-file.el or is it a candidat for
inclusion? (I've let the explanation of what it does in)

  Sam
-- 
Samuel Tardieu -- sam@ada.eu.org


--Multipart_Wed_Apr_23_10:08:27_1997-1
Content-Type: message/rfc822

From: Rolf Ebert <re@waporo.muc.de>
Newsgroups: comp.emacs.xemacs,comp.lang.ada
Subject: Re: Ada mode find-file.el file
Date: 21 Apr 1997 21:57:31 +0200
Organization: Rolf Ebert from home
Message-ID: <m24td0gppz.fsf@waporo.muc.de>
References: <335B4F9E.6F51@reading.ac.uk>

William Paul Berriss <W.P.Berriss@reading.ac.uk> writes:
> 
> Hi
> 
> I use Xemacs 19.15 on Solaris 2.5 and Ada mode.
> 
> I think I need the file *find-file.el* because I want
> to switch between package spec and body files using the
> Ada...Other File menu option on Xemacs, but it is greyed 
> out at the moment.
> 
> Can anyone tell me where I can obtain find-file.el?
> and how to use it (activate it)?
> 
> Thanks
> 
> Will Berriss
> ------------
> [large signature deleted]

I developed ada-mode using standard GNU Emacs.  FSF Emacs has find-file
since 19.2X (X>5, I don't remember)

I only recently switched to XEmacs and found out that XEmacs does not
provide find-file.  XEmacs includes almost every Emacs package available
on the Net, but it leaves out find-file, I don't know why.

find-file from Emacs-19.31 (my current version at home) work fine with
XEmacs-19.14 and 19.15. I include it at the end of my message.

Just put the file somewhere in your load-path (type C-h v load-path).
The best place is probably the directoy ending in site-lisp.

        Rolf
        ebert@pe-muc.de

[...standard header trimmed...]

;; PURPOSE:
;; This package features a function called ff-find-other-file, which performs 
;; the following function: 
;;
;;     When in a .c file, find the first corresponding .h file in a set
;;     of directories and display it, and vice-versa from the .h file.
;;
;; Many people maintain their include file in a directory separate to their
;; src directory, and very often you may be editing a file and have a need to
;; visit the "other file". This package searches through a set of directories
;; to find that file.
;;
;; THE "OTHER FILE", or "corresponding file", generally has the same basename,
;; and just has a different extension as described by the ff-other-file-alist 
;; variable:
;;
;;   '(("\\.cc$"  (".hh" ".h"))
;;     ("\\.hh$"  (".cc" ".C" ".CC" ".cxx" ".cpp")))
;;
;; If the current file has a .cc extension, ff-find-other-file will attempt
;; to look for a .hh file, and then a .h file in some directory as described
;; below. The mechanism here is to replace the matched part of the original
;; filename with each of the corresponding extensions in turn.
;;
;; Alternatively, there are situations where the filename of the other file
;; cannot be determined easily with regexps. For example, a .c file may
;; have two corresponding .h files, for its public and private parts, or
;; the filename for the .c file contains part of the pathname of the .h
;; file, as between src/fooZap.cc and include/FOO/zap.hh. In that case, the
;; format above can be changed to include a function to be called when the
;; current file matches the regexp:
;;
;;   '(("\\.cc$"  cc-function)
;;     ("\\.hh$"  hh-function))
;;
;; These functions must return a list consisting of the possible names of the 
;; corresponding file, with or without path. There is no real need for more 
;; than one function, and one could imagine the following value for cc-other-
;; file-alist:
;;
;;    (setq cc-other-file-alist
;;        '(("\\.cc$"  ff-cc-hh-converter)
;;          ("\\.hh$"  ff-cc-hh-converter)
;;          ("\\.c$"   (".h"))
;;          ("\\.h$"   (".c" ".cc" ".C" ".CC" ".cxx" ".cpp"))))
;; 
;; ff-cc-hh-converter is included at the end of this file as a reference.
;; 
;; SEARCHING is carried out in a set of directories specified by the
;; ff-search-directories variable:
;;
;;     ("." "../../src" "../include/*" "/usr/local/*/src/*" "$PROJECT/src")
;;
;; This means that the corresponding file will be searched for first in
;; the current directory, then in ../../src, then in one of the directories
;; under ../include, and so on. The star is _not_ a general wildcard
;; character: it just indicates that the subdirectories of this directory
;; must each be searched in turn. Environment variables will be expanded in
;; the ff-search-directories variable.
;;
;; If the point is on a #include line, the file to be #included is searched
;; for in the same manner. This can be disabled with the ff-ignore-include
;; variable, or by calling ff-get-other-file instead of ff-find-other-file.
;;
;; If the file was not found, ff-find-other-file will prompt you for where
;; to create the new "corresponding file" (defaults to the current directory),
;; unless the variable ff-always-try-to-create is set to nil. 
;;
;; GIVEN AN ARGUMENT (with the ^U prefix), ff-find-other-file will get the 
;; other file in another (the other?) window (see find-file-other-window and 
;; switch-to-buffer-other-window). This can be set on a more permanent basis 
;; by setting ff-always-in-other-window to t in which case the ^U prefix will 
;; do the opposite of what was described above.
;;
;; THERE ARE FIVE AVAILABLE HOOKS, called in this order if non-nil:
;;
;; - ff-pre-find-hooks     - called before the search for the other file starts
;; - ff-not-found-hooks    - called when the other file could not be found
;; - ff-pre-load-hooks     - called just before the other file is 'loaded'
;; - ff-file-created-hooks - called when the other file is created
;; - ff-post-load-hooks    - called just after the other file is 'loaded'
;;
;; The *load-hooks allow you to place point where you want it in the other
;; file. 

;; FEEDBACK:
;; Please send me bug reports, bug fixes, and extensions, so that I can
;; merge them into the master source.

;; CREDITS:
;; Many thanks go to TUSC Computer Systems Pty Ltd for providing an environ-
;; ment that made the development of this package possible.
;;
;; Many thanks also go to all those who provided valuable feedback throughout
;; the development of this package:
;;     Rolf Ebert in particular, Fritz Knabe, Heddy Boubaker, Sebastian Kremer,
;;     Vasco Lopes Paulo, Mark A. Plaksin, Robert Lang, Trevor West, Kevin 
;;     Pereira & Benedict Lofstedt.

;; Code:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

[...code trimmed...]

--Multipart_Wed_Apr_23_10:08:27_1997-1--

