im going to answer my question by myself! Finally i found a great solution for my problem.
I`ve found a great powerfull UserControl on code-projekt http://www.codeproject.com/Articles/42490/Using-AvalonEdit-WPF-Text-Editor
My way to the finall solution was:
Adding this to my .xml
xmlns:avalonEdit="http://icsharpcode.net/sharpdevelop/avalonedit"
And this
<avalonEdit:TextEditor Visibility="Hidden" x:Name="RTBAuftragNEU" Margin="32,413,243,279" KeyDown="RTBKunde_KeyDown" Panel.ZIndex="1" VerticalScrollBarVisibility="Disabled" HorizontalScrollBarVisibility="Disabled" > </avalonEdit:TextEditor>
Then put this to my class where i need it.
using (Stream s = System.Reflection.Assembly.GetExecutingAssembly().GetManifestResourceStream("ConsultingControls.highlight.xshd"))
{
using (XmlTextReader reader = new XmlTextReader(s))
{
RTBAuftragNEU.SyntaxHighlighting = HighlightingLoader.Load(reader, HighlightingManager.Instance);
}
}
Dont forget to create the XSHD file for the Syntax, you will find a complete tutorial on the codeproject site.
greetings, fridolin