Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-debug-dev] Presentation of "Execution Location" in editors


I like this plan a lot.  Losing selection, and thus any indication of the current line has always been annoying.  I vote for making this part of the debug model presentation, since the pluggability of presentations would make it easier for an implementor to change just the instruction pointer behavior.  If this lived in the editor, debug model implementors would have a harder time changing this behavior.

Joe




"Darin Wright" <Darin_Wright@xxxxxxx>
Sent by: platform-debug-dev-admin@xxxxxxxxxxx

08/30/2002 11:13 AM
Please respond to platform-debug-dev

       
        To:        platform-debug-dev@xxxxxxxxxxx
        cc:        
        Subject:        [platform-debug-dev] Presentation of "Execution Location" in editors



Following is a proposal for displaying a program's execution location (instruction pointer) in editors. (Related bug - http://bugs.eclipse.org/bugs/show_bug.cgi?id=1524).


Currently the (generic) debug UI displays the current execution location by selecting the line associated with the selected stack frame. This approach has a couple of problems:

* The selection is lost if the user clicks in an editor

* The implementation uses an IMarker, and assumes the editor is a text editor


To improve this, I suggest that the debug UI define a new interface which either an editor or a debug model presentation could implement (not sure which is best). The interface would be called something like "IExecutionLocationPresentation", and would define the following methods. (If the model presentation were the implementor, instead of the editor, the editor would also be passed along as a parameter)

* showExecutionLocation(IStackFrame)
* clearExecutionLocation()


The Debug UI would call these methods to display the current execution location as a program under debug suspends/resumes. It would be up to the implementation to determine how the location is rendered, and this API does not limit the presentation to text editors.  If a presentation/editor did not implement this interface, the current method of presentation would be used - i.e. line selection.


One benefit of having the debug model presentation responsibe for the execution location presentation is that an editor would not have to be aware of the debugger (although, it might want to be, to allow access to the internals of the editor to produce a better presentation).


Comments welcome.


Darin



Back to the top