
MultiLineDecoration: Decoration of a list of specified lines of text.LineDecoration: Decoration of a specified line of text.DoubleQuotedDecoration: Decoration of text between double quotes.MultiRegexWordDecoration: Decoration based on a list of strings sandwiched between word boundaries.MultiExplicitDecoration: Decoration explicitly specified as a list of starting positions and lengths.ExplicitDecoration: Decoration explicitly specified as a starting position and a length - simple but useful when working with selection.MultiStringDecoration: Decoration based on a list of Regular Expression strings.RegexDecoration: Decoration based on a single Regular Expression string.MultiStringDecoration: Decoration based on index positions of a list of strings.StringDecoration: Decoration based on index positions of a single string.At present, there are a number of premade decorations: A DecorationScheme is basically just a conveniently grouped collection of Decoration items.


Decorations fall into two major categories corresponding to the DecorationScheme and Decoration classes. Without adding Decorations, it is almost indistinguishable from the RichTextBox.
#Www codebox code#
The code should not be hard to use as the control is inherited from the RichTextBox. They all share the same basic decoration concept. I would like to think that CodeBox and its radically redesigned descendant CodeBox 2 would be useful even though this WinForms implementation is very different. The first two were built for use with WPF. This is the third CodeBox that I have put up.

My goal is to present this control and the optimizations that were necessary for it to run at a reasonable speed simply enough that a C# novice would be able to understand it. This article presents a WinForms text edit control that supports a flexible highlighting and word coloring decoration system.
