第三方编辑/语法高亮控制的建议 - WinForms
我正在寻找一个优质的WinForms组件,它支持语法高亮,代码折叠等。关键的标准是:第三方编辑/语法高亮控制的建议 - WinForms
- 稳定性
- 价值(价格)
- 能够轻松定制的语法高亮显示
- 重量轻
试用ScintillaNET这是各地优秀Scintilla控制一个.NET的WinForms包装。 Scintilla本身是一个免费的源代码编辑器组件,它非常可定制,并且具有您要求的所有功能。请参阅here获取屏幕截图。
与Scintilla.Net相比,增强ICSharpCode.TextEditor是微不足道的。 ICSharpCode.TextEditor的另一个巨大优势是可以自定义/构建自己的语法高亮显示,例如:https://github.com/icsharpcode/SharpDevelop/wiki/Syntax-highlighting。
但ICSharpCode.TextEditor并不稳定,它充满了AccessViolations:https://www.google.com.au/search?q=icsharpcode.texteditor+accessviolationexception
你可以看到这些AccessViolations第一手通过下载: http://www.codeproject.com/Articles/30936/Using-ICSharpCode-TextEditor
此版本在GitHub上的表现更好的WinForms,但在VSTO它仍然尖叫AccessViolations: https://github.com/KindDragon/ICSharpCode.TextEditor
同DigitalRune's version of the ICsharp.TextEditor。
我推荐最新的WPF实现:ICSharp.AvalonEdit。
如果您需要托管在此的WinForms WPF控件:
public Form1()
{
InitializeComponent();
ICSharpCode.AvalonEdit.TextEditor te = new ICSharpCode.AvalonEdit.TextEditor();
ElementHost host = new ElementHost();
host.Size = new Size(200, 100);
host.Location = new Point(100, 100);
host.Child = te;
this.Controls.Add(host);
}
一些商业的,我碰到(注意我不是在与这些公司下属): http://www.actiprosoftware.com/products/controls/windowsforms/syntaxeditor http://www.qwhale.net/products/editor.htm
SnippetCompiler http://www.sliver.com/dotnet/SnippetCompiler/也使用ActiPro作为它的编辑器。 – 2008-09-07 17:22:23
顺便说一句,如果有人奇怪,ActiPro不支持客户端配置文件。 – 2011-02-25 16:28:54