<p>I am looking for a Visual Studio add-in that would analyze the text around the cursor position and navigate to the corresponding class definition.</p>

<p>For example I have this XML file that is currently open:</p>

<pre><code>&lt;object id="abc" type="MyProject.Foo.Bar, MyProject"/&gt;
</code></pre>

<p>If I put the cursor somewhere between the double quotes on the <em>type</em> attribute the add-in should obtain the string <em>"MyProject.Foo.Bar, MyProject"</em> and search for all projects and project references in the current solution for the given type and if it finds one, it should navigate to the class definition (or metadata if the source code is not available in the current solution).</p>

<p>If such add-in doesn't exist I would greatly appreciate some pointers that could help me writing one.</p>

Well you could use the '
Code Definition Window
' that comes with the VS2008 IDE. When you place your cursor, the Code Def window dynamically updates with the source code for that type.
Works with regular source files.. don't have the IDE at hand to verify with XAML/XML
Also you could 'Jump to Symbol' key combo but you would need CodeRush Express add in for that. Shift+Ctrl+Q. More details
here
.