Our great sponsors
-
FastColoredTextBox
Fast Colored TextBox for Syntax Highlighting. The text editor component for .NET.
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
For the most part it's best to just use something like AvalonEdit that already implements it for you. There's some documentation and if you dig a long time ago there was a book about how it was made (along with SharpDevelop) that may still be findable.
You can check on GitHub for some projects that have done the same, something like https://github.com/PavelTorgashov/FastColoredTextBox
Or this one for csharp which is more complex https://github.com/PrismJS/prism/blob/master/components/prism-csharp.js