There is an example here that extend the Visual Studio 2010 editor: Image Insertion (but it’s tied to Visual Studio, not a generic solution)
There is an example here that extend the Visual Studio 2010 editor: Image Insertion (but it’s tied to Visual Studio, not a generic solution)