I am looking at the Roslyn September 2012 CTP with Reflector, and I noticed the following:

[ContentType("HTML")]
[Export(typeof(IVsTextViewCreationListener))]
[Export(typeof(IWpfTextViewCreationListener))]
[Export(typeof(VenusTextViewManager))]
[TextViewRole("PRIMARYDOCUMENT")]
internal sealed class VenusTextViewManager : IVsTextViewCreationListener, IWpfTextViewCreationListener
{
    // ...
}

Why is "HTML" passed into the constructor of ContentTypeAttribute, since Roslyn is for C# and VB.NET? Is it that the HTML implies some sort of rich text formatting? Or perhaps this is to support markup for the ASP.NET Razor engine?

有帮助吗?

解决方案

As you guessed, this is for support of aspx and cshtml/vbhtml files. We're hoping to find a better way to deal with the issues this class currently handles in a future release though.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top