/[hyperdoc]/src/slime.patch
ViewVC logotype

Contents of /src/slime.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations)
Sat Apr 24 20:55:46 2004 UTC (9 years, 11 months ago) by nsiivola
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +9 -6 lines
Use the new lookup interface.
1 ? fasl
2 Index: slime.el
3 ===================================================================
4 RCS file: /project/slime/cvsroot/slime/slime.el,v
5 retrieving revision 1.275
6 diff -u -r1.275 slime.el
7 --- slime.el 23 Apr 2004 22:09:11 -0000 1.275
8 +++ slime.el 24 Apr 2004 20:54:56 -0000
9 @@ -485,7 +485,7 @@
10 ("\C-m" slime-macroexpand-1 :prefixed t :inferior t)
11 ("\M-m" slime-macroexpand-all :prefixed t :inferior t)
12 ("\M-0" slime-restore-window-configuration :prefixed t :inferior t)
13 - ("\C-h" slime-hyperspec-lookup :prefixed t :inferior t :sldb t)
14 + ("\C-h" slime-hyperdoc-key :prefixed t :inferior t :sldb t)
15 ([(control meta ?\.)] slime-next-location :inferior t)
16 ;; Emacs20 on LinuxPPC signals a
17 ;; "Invalid character: 400000040, 2147479172, 0xffffffd8"
18 @@ -6619,6 +6619,20 @@
19 (defun sldb-xemacs-post-command-hook ()
20 (when (get-text-property (point) 'point-entered)
21 (funcall (get-text-property (point) 'point-entered))))
22 +
23 +
24 +;;; Hyperdoc
25 +(defun slime-hyperdoc-key ()
26 + (interactive)
27 + (slime-hyperdoc (symbol-name (slime-function-called-at-point/line))))
28 +
29 +(defun slime-hyperdoc (symbol-name)
30 + (interactive (list (slime-read-symbol "Hyperdoc for: ")))
31 + (slime-eval-async
32 + `(swank:hyperdoc ,symbol-name)
33 + (slime-buffer-package)
34 + (lambda (uri)
35 + (browse-url uri))))
36
37
38 ;;; Finishing up
39 Index: swank-sbcl.lisp
40 ===================================================================
41 RCS file: /project/slime/cvsroot/slime/swank-sbcl.lisp,v
42 retrieving revision 1.83
43 diff -u -r1.83 swank-sbcl.lisp
44 --- swank-sbcl.lisp 6 Apr 2004 10:42:53 -0000 1.83
45 +++ swank-sbcl.lisp 24 Apr 2004 20:54:56 -0000
46 @@ -40,6 +40,7 @@
47 (require 'sb-bsd-sockets)
48 (require 'sb-introspect)
49 (require 'sb-posix)
50 + (require 'hyperdoc)
51 )
52
53 (declaim (optimize (debug 3)))
54 Index: swank.lisp
55 ===================================================================
56 RCS file: /project/slime/cvsroot/slime/swank.lisp,v
57 retrieving revision 1.171
58 diff -u -r1.171 swank.lisp
59 --- swank.lisp 22 Apr 2004 21:37:50 -0000 1.171
60 +++ swank.lisp 24 Apr 2004 20:54:57 -0000
61 @@ -2063,6 +2063,12 @@
62 (with-connection (connection)
63 (simple-break))))))
64
65 +(defslimefun hyperdoc (string)
66 + (multiple-value-bind (name package-name internal-p)
67 + (tokenize-symbol-designator (case-convert-input string))
68 + (declare (ignore internal-p))
69 + (hyperdoc:lookup package-name name)))
70 +
71 ;;; Local Variables:
72 ;;; eval: (font-lock-add-keywords 'lisp-mode '(("(\\(defslimefun\\)\\s +\\(\\(\\w\\|\\s_\\)+\\)" (1 font-lock-keyword-face) (2 font-lock-function-name-face))))
73 ;;; End:

  ViewVC Help
Powered by ViewVC 1.1.5