Lessons Learned Creating A Visual Studio Text Adornment

Lucian Wischik, who if you ever get the chance, make sure you catch him presenting, shares some tips and a tutorial on creating a Visual Studio Text Adornment. He takes you from start to finish and the result, your first Text Adornment...

Visual Studio Text Adornment VSIX using Roslyn

A VSIX is a way to install plugins into Visual Studio. The kind of plugin I’m interested in right now is a text adornment. This lets you superimpose things (text, pictures, interactive controls) right on top of a code editor window.

It took me a frustrating day figuring out how to get started. This post is to save everyone else the frustration.

Install the Visual Studio SDK ...

Install Roslyn SDK ...

Create a new VSIX project ...

Add references ...

Add code for the Text Adornment ...

Run it!

Press F5 to run it. It should launch a new “experimental” instance of VS, with your VSIX installed into it. When you open any text document you should see the new adornment in yellow:




... [Click through to read it all and get the source]


Follow the discussion

  • Oops, something didn't work.

    Getting subscription
    Subscribe to this conversation

No comments

Sorry, no comments have been submitted yet.

Please make a comment below or check back later.

Comment on the post

Already have a Channel 9 account? Please sign in