Class Window
A Toplevel View that draws a frame around its region and has a "ContentView" subview where the contents are added.
Implements
System.Collections.IEnumerable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Terminal.Gui
Assembly: Terminal.Gui.dll
Syntax
public class Window : Toplevel, IEnumerable
Constructors
Window(ustring)
Initializes a new instance of the Window class with an optional title.
Declaration
public Window(ustring title = null)
Parameters
Type | Name | Description |
---|---|---|
NStack.ustring | title | Title. |
Window(ustring, Int32)
Initializes a new instance of the Window with
the specified frame for its location, with the specified border
an optional title.
Declaration
public Window(ustring title = null, int padding = 0)
Parameters
Type | Name | Description |
---|---|---|
NStack.ustring | title | Title. |
System.Int32 | padding | Number of characters to use for padding of the drawn frame. |
Window(Rect, ustring)
Initializes a new instance of the Window class with an optional title and a set frame.
Declaration
public Window(Rect frame, ustring title = null)
Parameters
Type | Name | Description |
---|---|---|
Rect | frame | Frame. |
NStack.ustring | title | Title. |
Window(Rect, ustring, Int32)
Initializes a new instance of the Window with
the specified frame for its location, with the specified border
an optional title.
Declaration
public Window(Rect frame, ustring title = null, int padding = 0)
Parameters
Type | Name | Description |
---|---|---|
Rect | frame | Frame. |
NStack.ustring | title | Title. |
System.Int32 | padding | Number of characters to use for padding of the drawn frame. |
Properties
Title
The title to be displayed for this window.
Declaration
public ustring Title { get; set; }
Property Value
Type | Description |
---|---|
NStack.ustring | The title. |
Methods
Add(View)
Add the specified view to the Terminal.Gui.Window.ContentView.
Declaration
public override void Add(View view)
Parameters
Type | Name | Description |
---|---|---|
View | view | View to add to the window. |
Overrides
GetEnumerator()
Enumerates the various Views in the embedded Terminal.Gui.Window.ContentView.
Declaration
public IEnumerator GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.IEnumerator | The enumerator. |
MouseEvent(MouseEvent)
Declaration
public override bool MouseEvent(MouseEvent mouseEvent)
Parameters
Type | Name | Description |
---|---|---|
MouseEvent | mouseEvent |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
Redraw(Rect)
Declaration
public override void Redraw(Rect bounds)
Parameters
Type | Name | Description |
---|---|---|
Rect | bounds |
Overrides
Remove(View)
Removes a widget from this container.
Declaration
public override void Remove(View view)
Parameters
Type | Name | Description |
---|---|---|
View | view |
Overrides
Remarks
RemoveAll()
Removes all widgets from this container.
Declaration
public override void RemoveAll()
Overrides
Remarks
Implements
System.Collections.IEnumerable