Function: semantic-idle-local-symbol-highlight-idle-function
semantic-idle-local-symbol-highlight-idle-function is a byte-compiled
function defined in idle.el.gz.
Signature
(semantic-idle-local-symbol-highlight-idle-function)
Documentation
Perform idle activity for the minor mode
semantic-idle-local-symbol-highlight-mode(var)/semantic-idle-local-symbol-highlight-mode(fun).
Source Code
;; Defined in /usr/src/emacs/lisp/cedet/semantic/idle.el.gz
(define-semantic-idle-service semantic-idle-local-symbol-highlight
"Highlight the tag and symbol references of the symbol under point.
Call `semantic-analyze-current-context' to find the reference tag.
Call `semantic-symref-hits-in-region' to identify local references."
(require 'pulse)
(when (semantic-idle-summary-useful-context-p)
(let* ((ctxt
(semanticdb-without-unloaded-file-searches
(semantic-analyze-current-context)))
(Hbounds (when ctxt (oref ctxt bounds)))
(target (when ctxt (car (reverse (oref ctxt prefix)))))
(tag (semantic-current-tag))
;; We use pulse, but we don't want the flashy version,
;; just the stable version.
(pulse-flag nil))
(when (and ctxt tag)
;; Highlight the original tag? Protect against problems.
(condition-case nil
(semantic-idle-symbol-maybe-highlight target)
(error nil))
;; Identify all hits in this current tag.
(when (semantic-tag-p target)
(require 'semantic/symref/filter)
(semantic-symref-hits-in-region
target (lambda (start end _prefix)
(when (/= start (car Hbounds))
(pulse-momentary-highlight-region
start end 'semantic-idle-symbol-highlight))
(semantic-throw-on-input 'symref-highlight))
(semantic-tag-start tag)
(semantic-tag-end tag)))))))