home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 5 / FreshFish_July-August1994.bin / bbs / util / jade-3.0.lha / Jade / lisp / help.jlc < prev    next >
Encoding:
Text File  |  1994-04-20  |  2.4 KB  |  21 lines

  1.  
  2. (setq help-buffer (make-buffer "*Help*") help-keymap (make-keylist))
  3.  
  4. (set-buffer-special help-buffer t)
  5.  
  6. (bind-keys help-keymap "a" (quote apropos-function) "e" (quote apropos-variable) "f" (quote describe-function) "h" (quote help-help) "ctrl-h" (quote help-help) "i" (quote info) "ctrl-i" (quote (info t)) "m" (quote describe-mode) "?" (quote help-help) "v" (quote describe-variable))
  7.  
  8. (defun help nil (lisp-code "\tHIKF#" [title "Type: a f h i m v -- h for more help" help-keymap next-keymap-path] 2))
  9.  
  10. (defun help-help nil (lisp-code "\tH\n H†\tH‡\n\tHˆ" [clear-buffer help-buffer insert "\nHelp mode -- Type one of the following:\n\na   `apropos-function'\n\tSearch for functions which match a regular expression.\nf   `describe-function'\n\tView the documentation for a particular function.\nh   `help-help'\n\tDisplay this text.\ni   `info'\n\tEnter the info hypertext viewer.\nm   `describe-mode'\n\tShow the documentation for the edit mode of the current buffer.\nv   `describe-variable'\n\tView the documentation and value of a variable." pos 1 goto-buffer goto help] 5))
  11.  
  12. (defun apropos-function (&optional regexp) (lisp-code "ÿ€Ž\tF ÿ€ŽH\tH†‡ Hˆ‰Š\n\nH‹\tHŒŽŽ\n\t" [regexp prompt "Regular Expression: " return clear-buffer help-buffer format "Apropos for expression %S:\n" print apropos fboundp goto-buffer goto pos 1] 4))
  13.  
  14. (defun apropos-variable (&optional regexp) (lisp-code "ÿ€Ž\tF ÿ€ŽH\tH†‡ Hˆ‰Š\n\nH‹\tH‹Œ\n\t" [regexp prompt "Regular Expression: " return clear-buffer help-buffer format "Apropos for expression %S:\n" print apropos boundp goto pos 1] 4))
  15.  
  16. (defun describe-function (&optional fun &aux doc) (lisp-code "ÿ€F ÿ€H\tF$H†\tH‡†ˆÿ€¥‰ HŠ†\tH‹Œ\n\t" [fun prompt-for-function return documentation doc clear-buffer help-buffer format "\n%s\n" "undocumented." goto-buffer goto pos 1] 4))
  17.  
  18. (defun describe-variable (&optional var &aux doc) (lisp-code "ÿ€F ÿ€HJ\nF$H†\tH‡†JKˆ‰\tŠ\tÿ€°‹HŒ†\tHŽ\n\t" [var prompt-for-variable return documentation doc clear-buffer help-buffer format "\nsymbol name: %s\ncurrent value: %S\n\n%s\n" symbol-name symbol-value "undocumented." goto-buffer goto pos 1] 6))
  19.  
  20. (defun describe-mode nil (lisp-code "\tHHD\t5qþ€¤†‡ˆ H‰Š‹‹\n\tE" [goto-buffer help-buffer clear-buffer documentation major-mode doc format "\n%s\n" mode-documentation goto pos 1] 4))
  21.