(:propertize which-func-current
local-map ,which-func-keymap
face which-func
- ;;mouse-face highlight ; currently not evaluated :-(
+ mouse-face mode-line-highlight
help-echo "mouse-1: go to beginning\n\
mouse-2: toggle rest visibility\n\
mouse-3: go to end")
"]")
"Format for displaying the function in the mode line."
+ :version "24.2" ; added mouse-face
:group 'which-func
:type 'sexp)
;;;###autoload (put 'which-func-format 'risky-local-variable t)
(funcall which-func-cleanup-function name)
name))))
+\f
+;;; Integration with other packages
+
+(defun which-func-update-ediff-windows ()
+ "Update Which-Function mode display for Ediff windows.
+This function is meant to be called from `ediff-select-hook'."
+ (when (eq major-mode 'ediff-mode)
+ (when ediff-window-A
+ (which-func-update-1 ediff-window-A))
+ (when ediff-window-B
+ (which-func-update-1 ediff-window-B))
+ (when ediff-window-C
+ (which-func-update-1 ediff-window-C))))
+
+(add-hook 'ediff-select-hook 'which-func-update-ediff-windows)
+
(provide 'which-func)
;;; which-func.el ends here