Class TextField
Text data entry widget
Inherited Members
Namespace: Terminal.Gui
Assembly: Terminal.Gui.dll
Syntax
public class TextField : Terminal.Gui.View
Remarks
The Entry widget provides Emacs-like editing functionality, and mouse support.
Constructors
TextField(ustring)
Public constructor that creates a text field, with layout controlled with X, Y, Width and Height.
Declaration
public TextField (NStack.ustring text);
Parameters
Type | Name | Description |
---|---|---|
NStack.ustring | text | Initial text contents. |
TextField(String)
Public constructor that creates a text field, with layout controlled with X, Y, Width and Height.
Declaration
public TextField (string text);
Parameters
Type | Name | Description |
---|---|---|
System.String | text | Initial text contents. |
TextField(Int32, Int32, Int32, ustring)
Public constructor that creates a text field at an absolute position and size.
Declaration
public TextField (int x, int y, int w, NStack.ustring text);
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | x | The x coordinate. |
System.Int32 | y | The y coordinate. |
System.Int32 | w | The width. |
NStack.ustring | text | Initial text contents. |
Properties
CanFocus
Declaration
public override bool CanFocus { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | To be added. |
CursorPosition
The current cursor position.
Declaration
public int CursorPosition { get; }
Property Value
Type | Description |
---|---|
System.Int32 | To be added. |
Frame
Declaration
public override Terminal.Gui.Rect Frame { get; set; }
Property Value
Type | Description |
---|---|
Rect | To be added. |
Secret
Sets the secret property.
Declaration
public bool Secret { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | To be added. |
Remarks
This makes the text entry suitable for entering passwords.
Text
Sets or gets the text in the entry.
Declaration
public NStack.ustring Text { get; set; }
Property Value
Type | Description |
---|---|
NStack.ustring | To be added. |
Methods
MouseEvent(MouseEvent)
Declaration
public override bool MouseEvent (Terminal.Gui.MouseEvent ev);
Parameters
Type | Name | Description |
---|---|---|
MouseEvent | ev | To be added. |
Returns
Type | Description |
---|---|
System.Boolean | To be added. |
PositionCursor()
Sets the cursor position.
Declaration
public override void PositionCursor ();
ProcessKey(KeyEvent)
Declaration
public override bool ProcessKey (Terminal.Gui.KeyEvent kb);
Parameters
Type | Name | Description |
---|---|---|
KeyEvent | kb | To be added. |
Returns
Type | Description |
---|---|
System.Boolean | To be added. |
Redraw(Rect)
Declaration
public override void Redraw (Terminal.Gui.Rect region);
Parameters
Type | Name | Description |
---|---|---|
Rect | region | To be added. |
Events
Changed
Changed event, raised when the text has clicked.
Declaration
public event EventHandler Changed;
Event Type
Type | Description |
---|---|
System.EventHandler | To be added. |
Remarks
Client code can hook up to this event, it is raised when the text in the entry changes.