Files
Terminal.Gui/UICatalog/Scenarios/SystemConsole.cs
BDisp 239191cde0 Fixes #1434. Regenerating the docs. (#1528)
* Fixes #1434. Regenerating the docs.

* Fixing warnings on docs regeneration and improving.
2021-12-18 05:33:40 -08:00

35 lines
853 B
C#

using Terminal.Gui;
namespace UICatalog.Scenarios {
[ScenarioMetadata (Name: "System Console", Description: "Not working - #518 - Enables System Console and exercises things")]
[ScenarioCategory ("Bug Repro")]
[ScenarioCategory ("Console")]
public class UseSystemConsole : Scenario {
public override void Init (Toplevel top, ColorScheme colorScheme)
{
Application.UseSystemConsole = true;
base.Init (top, colorScheme);
}
public override void RequestStop ()
{
base.RequestStop ();
Application.UseSystemConsole = false;
}
public override void Run ()
{
base.Run ();
}
public override void Setup ()
{
var pressMe = new Button ("Press me!") {
X = Pos.Center (),
Y = Pos.Center (),
};
pressMe.Clicked += () => MessageBox.Query (20, 7, "Hi", "Neat?", "Yes", "No");
Win.Add (pressMe);
}
}
}