When I use mouse-over on an Link (thanks to Tobias) it shows an Image and text. When I used display-local-help the image disappeared (perhaps due to lack of space in the message area). I want to start the mouse-over with any key. Therefore I need a function name.

enter image description here

  • If you have the answer then please consider accepting it. You can accept your own answer. That takes the question off the unanswered questions list.
    – Drew
    Commented Dec 27, 2018 at 3:59

2 Answers 2


Not a real solution, but does do some of what you want:

  (defun my/show-tooltip ()
        ((tooltip-frame-parameters '((left . 100) (top . 200)))
         (text (get-text-property (point) 'help-echo)))
      (if (stringp text) (tooltip-show text))))

What's missing to be a real solution:

  • the help-echo property is not necessarily a string, it can also be a function or any expression. I expect this to be easily solvable. See the description of the help-echo property in the elisp manual.

  • I don't know how to get graphic coordinates from a buffer position (need to put them as left and top in tooltip-frame-parameters).

  • I have no idea if a display property on the string is honored by tooltip-show.


Many Thanks !! It works. I had used pos-tip-show. It also works with a button with tooltip-show. Here is the code for displaying a link with image and text. I simplified the example a bit so that it works without any additional functions. I wish you all a lot of fun! Andreas

 (defun display-local-help-als-tooltip (&optional arg)
  "Display of the tooltip with the keyboard instead of the mouse.
Template was display-local-help."
  (interactive "P")
  (let ((help (help-at-pt-kbd-string)))
    (if help
        help )
      (if (not arg) (tooltip-show
        "No indication available at this point.") ))))

(defun wikipedia-tooltip (window object position)
  "Tooltip with image and text."
      (goto-char position)
       (let ((path (org-element-property :path (org-element-context)))(beg) (end) (text)(imgfile) (img) (s))
     ;;Here the image should be inserted dynamically.
     (setq imgfile (format "x:/Temp/milk.jpg")) ; path
     ;; The text is actually determined by a function.
     (setq text "Milk is very ...")
    (if (file-exists-p imgfile)
      ;; If a picture exists, show it with the text.
      (setq img (create-image (expand-file-name imgfile)
                  'imagemagick nil :width 300))
      (concat (propertize " "
                  'display img) (format "\n%s" text)))
      ;; No picture available, then just show the text.

(defun wikipedia-link-face (path)
    '(:foreground "red" ))

(org-link-set-parameters "wikipedia"         
         :help-echo 'wikipedia-tooltip 
         :face 'wikipedia-link-face)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.