public CSharpTagger(RadCodeEditor editor) : base(editor) { }
private void SetCodeViewerLineNumbersBackgroundToTransparent(RadCodeEditor codeViewer) { codeViewer.Margins.ScrollableLeft.Clear(); codeViewer.Margins.ScrollableLeft.Add(new Telerik.Windows.Controls.CodeEditor.UI.Margins.LineNumberMargin(codeViewer) { Background = System.Windows.Media.Brushes.Transparent }); }
public VisualBasicTagger(RadCodeEditor editor) : base(editor) { }
private void PrepareSyntaxHighlighting(RadCodeEditor codeViewer, string language) { switch (language) { case "cs": codeViewer.TaggersRegistry.RegisterTagger(new CSharpTagger(codeViewer)); break; case "vb": codeViewer.TaggersRegistry.RegisterTagger(new VisualBasicTagger(codeViewer)); break; case "xaml": default: codeViewer.TaggersRegistry.RegisterTagger(new XamlTagger(codeViewer)); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlAttribute, XamlSyntaxHighlightingHelper.XamlAttributeFormatDefinition); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlElement, XamlSyntaxHighlightingHelper.XamlElementFormatDefinition); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlComment, XamlSyntaxHighlightingHelper.XamlCommentFormatDefinition); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlContent, XamlSyntaxHighlightingHelper.XamlContentFormatDefinition); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlString, XamlSyntaxHighlightingHelper.XamlStringFormatDefinition); codeViewer.TextFormatDefinitions.AddLast(XamlSyntaxHighlightingHelper.XamlTag, XamlSyntaxHighlightingHelper.XamlTagFormatDefinition); break; } }