Reputation: 3259
I`m working in a serial terminal project developed in VB.NET.
I need to display a lot of formatted (color, font styles) text data in a read-only control (the incoming serial data). I don`t know if it's a good idea to use richtext control or a grid, or there's a better third party control?
Thanks
Upvotes: 0
Views: 815
Reputation: 55039
I think the RichTextBox
would be a good place to start since it's included and then you could upgrade to a 3rd party control if you hit any limitations (I'm assuming that cost is important).
Please note though that it can be a bit slow at colouring text depending on the method used. This article shows a supposedly (I haven't tried it) faster way of doing it:
http://codebetter.com/blogs/patricksmacchia/archive/2008/07/07/some-richtextbox-tricks.aspx
Upvotes: 0
Reputation:
I've used Scintilla.NET for this sort of thing before: http://scintillanet.codeplex.com/
It's designed for use in text editors, but it can be made read-only, and it's pretty quick even for large quantities of text. You get efficient per-character control over colours and basic text styling, though not to the same extent as the Rich Edit control.
Negative points are that it's based on a control designed for use from C++ code, so there's not much in the way of .NET-specific documentation. And the .NET code is in C#, so it's probably best if you have a passing familiarity with that.
Upvotes: 1