513 |
(numberp elp-report-limit) |
(numberp elp-report-limit) |
514 |
(< cc elp-report-limit)) |
(< cc elp-report-limit)) |
515 |
nil |
nil |
516 |
(insert symname) |
(elp-output-insert-symname symname) |
517 |
(insert-char 32 (+ elp-field-len (- (length symname)) 2)) |
(insert-char 32 (+ elp-field-len (- (length symname)) 2)) |
518 |
;; print stuff out, formatting it nicely |
;; print stuff out, formatting it nicely |
519 |
(insert callcnt) |
(insert callcnt) |
525 |
(insert atstr)) |
(insert atstr)) |
526 |
(insert "\n")))) |
(insert "\n")))) |
527 |
|
|
528 |
|
(defvar elp-results-symname-map |
529 |
|
(let ((map (make-sparse-keymap))) |
530 |
|
(define-key map [mouse-2] 'elp-results-jump-to-definition-by-mouse) |
531 |
|
(define-key map "\C-m" 'elp-results-jump-to-definition) |
532 |
|
map) |
533 |
|
"Keymap used on the function name column." ) |
534 |
|
|
535 |
|
(defun elp-results-jump-to-definition-by-mouse (event) |
536 |
|
"Jump to the definition of the function under the place specified by EVENT." |
537 |
|
(interactive "e") |
538 |
|
(posn-set-point (event-end event)) |
539 |
|
(elp-results-jump-to-definition)) |
540 |
|
|
541 |
|
(defun elp-results-jump-to-definition () |
542 |
|
"Jump to the definition of the function under the point." |
543 |
|
(interactive) |
544 |
|
(find-function (get-text-property (point) 'elp-symname))) |
545 |
|
|
546 |
|
(defun elp-output-insert-symname (symname) |
547 |
|
;; Insert SYMNAME with text properties. |
548 |
|
(insert (propertize symname |
549 |
|
'elp-symname (intern symname) |
550 |
|
'keymap elp-results-symname-map |
551 |
|
'mouse-face 'highlight |
552 |
|
'help-echo (substitute-command-keys "\\{elp-results-symname-map}")))) |
553 |
|
|
554 |
;;;###autoload |
;;;###autoload |
555 |
(defun elp-results () |
(defun elp-results () |
556 |
"Display current profiling results. |
"Display current profiling results. |