, SteveRichter wrote

this is not very difficult to do. In a visual studio addin you code an DebuggerEvents.OnEnterBreakMode event handler.

1
2
3
_debugEvents = _applicationObject.Events.DebuggerEvents;
_debugEvents.OnEnterBreakMode +=
new _dispDebuggerEvents_OnEnterBreakModeEventHandler(BreakHandler);

Your addin creates a ToolWindow that hosts a WPF user control ( which in turn contains a Canvas ).

The OnEnterBreakMode event handler accesses the Debugger.CurrentStackFrame from the DTE2 application object:

1
var sf = _applicationObject.Debugger.CurrentStackFrame;

From the StackFrame you get a collection of Expression from the Arguments and Locals collections:

1
2
3
4
5
6
7
foreach (var item in sf.Locals)
{
  if (item is EnvDTE.Expression)
  {
    var exprItem = item as EnvDTE.Expression;
  }
}

Hooking up to the code on the call stack I assume is done with Project Roslyn.

Working with the values of the variables is a bit limited in my experience. The Expression object.Value property only returns the ToString( ) contents of an object and its members.

So unfortunately as it turns out this only works with managed code. It does not look like this is an open source project either.

Steve, do you think your technique above will also work with unmanaged code? And will it work in non-Ultimate versions?

While the Debugger Canvas plugin is impressive, its feature set is actually quite limited (there are some bugs too - at some point I could no longer switch/close tabs anymore). I wonder how complex such a project would really be if done from scratch.