X-Git-Url: http://git.chise.org/gitweb/?p=chise%2Fxemacs-chise.git.1;a=blobdiff_plain;f=lisp%2Ffinder.el;h=6124ce8de2d1a9ef09cbd5928d52af44217a26bc;hp=8c9594aa62ce70fb3d22c97b9adf813ae78eec79;hb=8ba3626da629f1b4ecafae24c85f3d0cb3bf8b8e;hpb=77dcef404dc78635f6ffa8f71a803d2bc7cc8921 diff --git a/lisp/finder.el b/lisp/finder.el index 8c9594a..6124ce8 100644 --- a/lisp/finder.el +++ b/lisp/finder.el @@ -78,41 +78,48 @@ directories to view or extract information from package source code.") `( (abbrev . "abbreviation handling, typing shortcuts, macros") (bib . "code related to the `bib' bibliography processor") + (build . "code used to build XEmacs") (c . "C, C++, and Objective-C language support") (calendar . "calendar and time management support") (comm . "communications, networking, remote access to files") + (content . "contains content (menu/dialog box descs, text, images, &c)") (data . "support for editing files of data") - (docs . "support for Emacs documentation") - (dumped . "files preloaded into Emacs") + (docs . "support for XEmacs documentation") + (dumped . "files preloaded into XEmacs") (emulations . "emulations of other editors") (extensions . "Emacs Lisp language extensions") (faces . "support for multiple fonts") - (frames . "support for Emacs frames and window systems") + (frames . "support for XEmacs frames and window systems") (games . "games, jokes and amusements") + (gui . "support for menubars, dialog boxes, and other GUI features") (hardware . "support for interfacing with exotic hardware") (help . "support for on-line help systems") (hypermedia . "support for links between text or other media types") (i18n . "internationalization and alternate character-set support") - (internal . "code for Emacs internals, build process, defaults") + (internal . "code implementing core functionality in XEmacs") (languages . "specialized modes for editing programming languages") (lisp . "Lisp support, including Emacs Lisp") (local . "code local to your site") - (maint . "maintenance aids for the Emacs development group") (mail . "modes for electronic-mail handling") + (maint . "maintenance aids for the Emacs development group") (matching . "various sorts of searching and matching") (mouse . "mouse support") + (mswin . "support for anything running on MS Windows") ,(when (featurep 'mule) (cons 'mule "multi-language extensions")) (news . "support for netnews reading and posting") (oop . "support for object-oriented programming") (outlines . "support for hierarchical outlining") (processes . "process, subshell, compilation, and job control support") + (services . "provides services for use by other programs (cf `user')") (terminals . "support for terminal types") (tex . "code related to the TeX formatter") (tools . "programming tools") (unix . "front-ends/assistants for, or emulators of, UNIX features") + (user . "program interacts directly with the user (cf `services'") (vms . "support code for vms") (wp . "word processing") + (www . "support for the Web (WWW, the World Wide Web)") )) (defvar finder-mode-map nil) @@ -150,7 +157,9 @@ arguments compiles from `load-path'." (let ((processed nil) (directory-abbrev-alist (append - (mapcar (function (lambda (dir) (cons dir ""))) + (mapcar (function (lambda (dir) + (cons (concat "^" (regexp-quote dir)) + ""))) finder-abbreviate-directory-list) directory-abbrev-alist)) (using-load-path)) @@ -167,7 +176,7 @@ arguments compiles from `load-path'." (lambda (d) (mapcar (lambda (f) - (when (not (member f processed)) + (when (and (not (member f processed)) (file-readable-p f)) (let (summary keystart keywords) (setq processed (cons f processed)) (if (not finder-compile-keywords-quiet) @@ -278,15 +287,20 @@ arguments compiles from `load-path'." found) (while (and dirs (not found)) (if (file-exists-p (expand-file-name (concat file ".el") (car dirs))) - (setq found (expand-file-name file (car dirs))) + (setq found (expand-file-name (concat file ".el") (car dirs))) (if (file-exists-p (expand-file-name file (car dirs))) (setq found (expand-file-name file (car dirs))))) (setq dirs (cdr dirs))) found))) +;;;###autoload (defun finder-commentary (file) - (interactive) - (let* ((str (lm-commentary (finder-find-library file)))) + "Display FILE's commentary section. +FILE should be in a form suitable for passing to `locate-library'." + (interactive "sLibrary name: ") + (let* ((str (lm-commentary (or (finder-find-library file) + (finder-find-library (concat file ".el")) + (error "Can't find library %s" file))))) (if (null str) (error "Can't find any Commentary section")) (pop-to-buffer "*Finder*") @@ -391,7 +405,7 @@ arguments compiles from `load-path'." "\\\\[finder-select] = select, \\[finder-list-keywords] = keywords, \\[finder-edit] = edit, \\[finder-view] = view, \\[finder-exit] = quit, \\[finder-summary] = help"))) (defun finder-exit () - "Exit Finder mode and kill the buffer" + "Exit Finder mode and kill the buffer." (interactive) ;; XEmacs change (or (one-window-p t 0)