;; customization stuff
(defgroup speedbar nil
"File and tag browser frame."
- :group 'tags
+ :group 'etags
:group 'tools
:group 'convenience
:version "20.3")
(looking-at "[0-9]+: *\\[[+-]\\] [^ \n]+ \\*?[!#]$"))]
)
"Additional menu items while in file-mode.")
-
+
(defvar speedbar-easymenu-definition-trailer
(append
(if (and (featurep 'custom) (fboundp 'custom-declare-variable))
(if (fboundp 'frame-parameter)
(defalias 'speedbar-frame-parameter 'frame-parameter)
-
+
(defun speedbar-frame-parameter (frame parameter)
"Return FRAME's PARAMETER value."
(cdr (assoc parameter (frame-parameters frame)))))
"Refresh the current speedbar display, disposing of any cached data."
(interactive)
(let ((dl speedbar-shown-directories)
- (dm (and (boundp 'deactivate-mark) deactivate-mark)))
+ deactivate-mark)
(while dl
(adelete 'speedbar-directory-contents-alist (car dl))
(setq dl (cdr dl)))
;; Reset the timer in case it got really hosed for some reason...
(speedbar-set-timer speedbar-update-speed)
(if (<= 1 speedbar-verbosity-level)
- (speedbar-message "Refreshing speedbar...done"))
- (if (boundp 'deactivate-mark) (setq deactivate-mark dm))))
+ (speedbar-message "Refreshing speedbar...done"))))
(defun speedbar-item-load ()
"Load the item under the cursor or mouse if it is a Lisp file."
(if tag-button-function 'speedbar-highlight-face nil)
tag-button-function tag-button-data))
))
-
+
(defun speedbar-change-expand-button-char (char)
"Change the expansion button character to CHAR for the current line."
(save-excursion
(speedbar-insert-generic-list indent lst
'speedbar-tag-expand
'speedbar-tag-find))
-
+
(defun speedbar-insert-etags-list (indent lst)
"At level INDENT, insert the etags generated LST."
(speedbar-insert-generic-list indent lst
`speedbar-mode-functions-list' as `speedbar-line-path'."
(let ((rf (speedbar-fetch-replacement-function 'speedbar-line-path)))
(if rf (funcall rf depth) default-directory)))
-
+
(defun speedbar-files-line-path (&optional depth)
"Retrieve the pathname associated with the current line.
This may require traversing backwards from DEPTH and combining the default
(forward-char -2)
(speedbar-do-function-pointer))
(error (speedbar-position-cursor-on-line)))))
-
+
(defun speedbar-flush-expand-line ()
"Expand the line under the cursor and flush any cached information."
(interactive)
(speedbar-expand-line 1))
-
+
(defun speedbar-contract-line ()
"Contract the line under the cursor."
(interactive)
TEXT is the button clicked on. TOKEN is the directory to follow.
INDENT is the current indentation level and is unused."
(if (string-match "^[A-z]:$" token)
- (setq default-directory (concat token (char-to-string directory-sep-char)))
+ (setq default-directory (concat token "/"))
(setq default-directory token))
;; Because we leave speedbar as the current buffer,
;; update contents will change directory without
(:background "green"))
(((class color) (background dark))
(:background "sea green"))
- (((class grayscale monochrome)
+ (((class grayscale mono)
(background light))
(:background "black"))
- (((class grayscale monochrome)
+ (((class grayscale mono)
(background dark))
(:background "white")))
"Face used for highlighting buttons with the mouse."
(defalias 'defimage-speedbar 'defimage)
(if (not (fboundp 'make-glyph))
-
+
(defmacro defimage-speedbar (variable imagespec docstring)
"Don't bother loading up an image...
Argument VARIABLE is the variable to define.