VisualStudioExtension.md
June 24, 2019 ยท View on GitHub
Installing Visual Studio extension
Visual Studio marketplace
Open Extensions and Updates and in Online gallery search for SharpDebug.VS extension.
Open VSIX Gallery
VSIX gallery will provide access to newest versions of extensions.
Open Options/Environment/Extensions and Updates. Add additional gallery: http://vsixgallery.com/feed/
Open Extensions and Updates and in new gallery search for SharpDebug.VS extension.

Automatic visualizations
std::any
Without extension:
With extension installed:

cv::Mat (OpenCV images)

User defined visualizations
In order to define new visualizations, you need to do following:
- Define initialization script that will define/reference user type
- Define NatVis file that will contain all the types that should be visualized
Initialization script
By default, engine will load initialization script relative to the default project location: `SharpDebug/init.csx'.
You can see more about how to define user types.
Learn more about how to reference user types in tutorials.
User type definition in NatVis
Here is an example NatVis file:
<?xml version="1.0" encoding="utf-8"?>
<AutoVisualizer xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<Type Name="MyUserType">
<CustomVisualizer VisualizerId="{401DAED1-A74F-49F3-9B03-66786EBF65B6}"/>
</Type>
</AutoVisualizer>
Interactive mode
Learn more about easier scripting in interactive mode.
Open interactive mode window by clicking: View / Other Windows / C# DebugSript interactive window.
Note that interactive mode is active only while in debugger break mode.
Executing scripts
Use #load command to execute scripts:
#load "script_path.csx"
Clearing interactive window
Use #clear command to clear interactive window.
Reseting interactive mode
#reset command will clear all stored variables and loaded scripts, start over and reload initialization script.