I am writing a Visual Studio extension that hovers above everything inside the text editor (above selections, text, etc).
[Export(typeof(IWpfTextViewCreationListener))]
[ContentType("csharp")]
[TextViewRole(PredefinedTextViewRoles.Interactive)]
internal sealed class MyAdornmentFactory : MyAdornmentFactoryBase, IWpfTextViewCreationListener
{
[Export(typeof(AdornmentLayerDefinition))]
[Name("MyName")]
[Order(After = PredefinedAdornmentLayers.Text, Before = PredefinedAdornmentLayers.Caret)]
[TextViewRole(PredefinedTextViewRoles.Interactive)]
public AdornmentLayerDefinition EditorAdornmentLayer;
// ...
}
Problem is, that my WPF UserControl always "hides" behind the text - no matter how I play with the OrderAttribute.
Am i doing something wrong? is there something else that can influence this behavior?
EDIT: I can now confirm that it ~sometimes~ work, possibly with connection to running without debugging... does anybody know of a related visual studio bug?