Home Intro Announce FAQ Docs Download Mail Status Bugs Users Related FM Tools

PVS Bug 645


Synopsis:        mouse-show-declaration for XEmacs
Severity:        serious
Priority:        medium
Responsible:     owre
State:           analyzed
Class:           sw-bug
Arrival-Date:    Fri Jan  4 15:45:00 2002
Originator:      Jerry James
Organization:    eecs.ku.edu
Release:         PVS 2.4
Environment: 
 System:          
 Architecture: 

Description: 
  The function mouse-show-declaration in pvs-browser.el uses several
  functions that are available in Emacs, but not in XEmacs.  Attempting to
  use it on XEmacs generates a void-function error.  Here is a version
  that works on XEmacs 21.4.4.  I don't have other versions handy for
  testing, unfortunately.
  
  
  (defun mouse-show-declaration (event)
    "Show declaration of symbol at mouse pointer.
  
  The mouse-show-declaration command is used to determine the declaration
  associated with a name.  Positioning the mouse pointer on a name in the
  specification and typing S-mouse-2 yields a pop-up buffer displaying the
  declaration.  This command is useful to determine the type of a name,
  or the resolution determined by the typechecker for an overloaded name."
    (interactive "e")
    (if (and (mouse-event-p event) (event-over-text-area-p event))
        (progn
  	(select-window (event-window event))
  	(save-excursion
  	  (goto-char (event-point event) (event-buffer event))
  	  (call-interactively 'show-declaration)))
      (error "Cursor not in text area of window")))
  
  
  -- 
  Jerry James
  Assistant Professor
  EECS Department
  University of Kansas
  

How-To-Repeat: 

Fix: 
Modified the mouse-show-declaration to work with both Emacs and Xemacs by
incorporating the above code (which won't work with Emacs) into the
existing function.  Also checked that this works with Emacs 21.
Home Intro Announce FAQ Docs Download Mail Status Bugs Users Related FM Tools