
I'm trying to reproduce the current line highlighting style that SE for WinForms uses. The SE for WPF documentation states that only the foreground property of the default CurrentLine highlighting style is update-able, so I thought I could define a custom highlighting style and override the default style, but I can't seem to get a background color to apply. Here's the code that I'm using:
Dim SpecialTypes As New DisplayItemClassificationTypeProvider(AmbientHighlightingStyleRegistry.Instance)
SpecialTypes.RegisterAll()
AmbientHighlightingStyleRegistry.Instance.Register(SpecialTypes.CurrentLine, New Highlighting.Implementation.HighlightingStyle(Brushes.Red, Brushes.Red), True)
The foreground color gets applied, but the background doesn't. I'm sure I'm missing something, but am at a loss as to what.
Thanks... Rick