Class ProgressBar
Implements
Inherited Members
Namespace: Terminal.Gui
Assembly: Terminal.Gui.dll
Syntax
public class ProgressBar : View, IEnumerable
Remarks
ProgressBar can operate in two modes, percentage mode, or activity mode. The progress bar starts in percentage mode and setting the Fraction property will reflect on the UI the progress made so far. Activity mode is used when the application has no way of knowing how much time is left, and is started when the Pulse() method is called. Call Pulse() repeatedly as progress is made.
Constructors
ProgressBar()
Declaration
public ProgressBar()
ProgressBar(Rect)
Declaration
public ProgressBar(Rect rect)
Parameters
Type | Name | Description |
---|---|---|
Rect | rect | Rect. |
Properties
Fraction
Declaration
public float Fraction { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The fraction representing the progress. |
Methods
Pulse()
Declaration
public void Pulse()
Remarks
Redraw(Rect)
Declaration
public override void Redraw(Rect region)
Parameters
Type | Name | Description |
---|---|---|
Rect | region |
Overrides
Remarks
Always use Bounds (view-relative) when calling Redraw(Rect), 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 globaly on the driver.
Overrides of Redraw(Rect) must ensure they do not set Driver.Clip
to a clip region
larger than the region
parameter.