/[emacs]/emacs/lisp/info.el
ViewVC logotype

Diff of /emacs/lisp/info.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.446 by rfrancoise, Sat Sep 24 13:44:02 2005 UTC revision 1.447 by cyd, Sun Oct 2 03:11:03 2005 UTC
# Line 4012  This will add a speedbar major display m Line 4012  This will add a speedbar major display m
4012    (speedbar-change-initial-expansion-list "Info")    (speedbar-change-initial-expansion-list "Info")
4013    )    )
4014    
 (eval-when-compile (defvar speedbar-attached-frame))  
   
4015  (defun Info-speedbar-hierarchy-buttons (directory depth &optional node)  (defun Info-speedbar-hierarchy-buttons (directory depth &optional node)
4016    "Display an Info directory hierarchy in speedbar.    "Display an Info directory hierarchy in speedbar.
4017  DIRECTORY is the current directory in the attached frame.  DIRECTORY is the current directory in the attached frame.
# Line 4030  specific node to expand." Line 4028  specific node to expand."
4028      ;; being known at creation time.      ;; being known at creation time.
4029      (if (not node)      (if (not node)
4030          (speedbar-with-writable (insert "Info Nodes:\n")))          (speedbar-with-writable (insert "Info Nodes:\n")))
4031      (let ((completions nil)      (let ((completions nil))
4032            (cf (selected-frame)))        (speedbar-select-attached-frame)
       (select-frame speedbar-attached-frame)  
4033        (save-window-excursion        (save-window-excursion
4034          (setq completions          (setq completions
4035                (Info-speedbar-fetch-file-nodes (or node '"(dir)top"))))                (Info-speedbar-fetch-file-nodes (or node '"(dir)top"))))
4036        (select-frame cf)        (select-frame speedbar-frame)
4037        (if completions        (if completions
4038            (speedbar-with-writable            (speedbar-with-writable
4039             (dolist (completion completions)             (dolist (completion completions)
# Line 4052  specific node to expand." Line 4049  specific node to expand."
4049  (defun Info-speedbar-goto-node (text node indent)  (defun Info-speedbar-goto-node (text node indent)
4050    "When user clicks on TEXT, go to an info NODE.    "When user clicks on TEXT, go to an info NODE.
4051  The INDENT level is ignored."  The INDENT level is ignored."
4052    (select-frame speedbar-attached-frame)    (speedbar-select-attached-frame)
4053    (let* ((buff (or (get-buffer "*info*")    (let* ((buff (or (get-buffer "*info*")
4054                     (progn (info) (get-buffer "*info*"))))                     (progn (info) (get-buffer "*info*"))))
4055           (bwin (get-buffer-window buff 0)))           (bwin (get-buffer-window buff 0)))
# Line 4062  The INDENT level is ignored." Line 4059  The INDENT level is ignored."
4059            (raise-frame (window-frame bwin)))            (raise-frame (window-frame bwin)))
4060        (if speedbar-power-click        (if speedbar-power-click
4061            (let ((pop-up-frames t)) (select-window (display-buffer buff)))            (let ((pop-up-frames t)) (select-window (display-buffer buff)))
4062          (select-frame speedbar-attached-frame)          (speedbar-select-attached-frame)
4063          (switch-to-buffer buff)))          (switch-to-buffer buff)))
4064      (if (not (string-match "^(\\([^)]+\\))\\([^.]+\\)$" node))      (if (not (string-match "^(\\([^)]+\\))\\([^.]+\\)$" node))
4065          (error "Invalid node %s" node)          (error "Invalid node %s" node)
# Line 4128  NODESPEC is a string of the form: (file) Line 4125  NODESPEC is a string of the form: (file)
4125        (nreverse completions))))        (nreverse completions))))
4126    
4127  ;;; Info mode node listing  ;;; Info mode node listing
4128  ;; FIXME: Seems not to be used.  -stef  ;; This is called by `speedbar-add-localized-speedbar-support'
4129  (defun Info-speedbar-buttons (buffer)  (defun Info-speedbar-buttons (buffer)
4130    "Create a speedbar display to help navigation in an Info file.    "Create a speedbar display to help navigation in an Info file.
4131  BUFFER is the buffer speedbar is requesting buttons for."  BUFFER is the buffer speedbar is requesting buttons for."
# Line 4136  BUFFER is the buffer speedbar is request Line 4133  BUFFER is the buffer speedbar is request
4133                        (let ((case-fold-search t))                        (let ((case-fold-search t))
4134                          (not (looking-at "Info Nodes:"))))                          (not (looking-at "Info Nodes:"))))
4135        (erase-buffer))        (erase-buffer))
4136    (Info-speedbar-hierarchy-buttons nil 0)    (Info-speedbar-hierarchy-buttons nil 0))
   )  
4137    
4138  (dolist (mess '("^First node in file$"  (dolist (mess '("^First node in file$"
4139                  "^No `.*' in index$"                  "^No `.*' in index$"

Legend:
Removed from v.1.446  
changed lines
  Added in v.1.447

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26