Table of Contents

Method Draw

Namespace
Terminal.Gui
Assembly
Terminal.Gui.dll

Draw()

Draws the view if it needs to be drawn. Causes the following virtual methods to be called (along with their related events): OnDrawContent(Rectangle), OnDrawContentComplete(Rectangle).

public void Draw()

Remarks

The view will only be drawn if it is visible, and has any of NeedsDisplay, SubViewNeedsDisplay, or LayoutNeeded set.

Always use Viewport (view-relative) when calling OnDrawContent(Rectangle), NOT Frame (superview-relative).

Views should set the color that they want to use on entry, as otherwise this will inherit the last color that was set globally on the driver.

Overrides of OnDrawContent(Rectangle) must ensure they do not set Driver.Clip to a clip region larger than the property, as this will cause the driver to clip the entire region.