Table of Contents

Class Code

Namespace
Terminal.Gui.Views
Assembly
Terminal.Gui.dll

A read-only view that renders syntax-highlighted source code.

public class Code : View, IDisposable, ISupportInitializeNotification, ISupportInitialize, IDesignable
Inheritance
Code
Implements
Inherited Members
Extension Methods

Remarks

Code demo

Constructors

Code()

Initializes a new instance of the Code class.

Properties

Language

Gets or sets the language hint used for syntax highlighting.

SyntaxHighlighter

Gets or sets the syntax highlighter used to tokenize Text.

Text

Gets or sets the source text to render.

Methods

OnClearingViewport()

Called when the Viewport is to be cleared.

OnDrawingContent(DrawContext?)

Called when the View's content is to be drawn. The default implementation does nothing.