C# Class IrcShark.Extensions.Terminal.ConsoleTerminal

This class allows the TerminalExtension to use the local Console as as a terminal for a user.
Inheritance: ITerminal
Mostrar archivo Open project: hapm/IrcShark

Private Properties

Property Type Description
Clear void
CmdBackspace void
CmdBackwardWord void
CmdDebug void
CmdDeleteBackword void
CmdDeleteChar void
CmdDeleteWord void
CmdDone void
CmdEnd void
CmdForwardWord void
CmdHistoryNext void
CmdHistoryPrev void
CmdHome void
CmdKillToEOF void
CmdLeft void
CmdRefresh void
CmdReverseSearch void
CmdRight void
CmdTabOrComplete void
CmdYank void
ComputeRendered void
EditLoop void
ForceCursor void
HandleChar void
HistoryUpdateLine void
InitText void
InsertChar void
InsertTextAtCursor void
InterruptEdit void
Render void
RenderAfter void
RenderFrom void
ReverseSearch void
SearchAppend void
SetPrompt void
SetSearchPrompt void
SetText void
TextToRenderPos int
TextToScreenPos int
UpdateCursor void
UpdateHomeRow void
WordBackward int
WordForward int
WriteWaitingRequests void

Public Methods

Method Description
ConsoleTerminal ( ) : System

Initializes a new instance of the ConsoleTerminal class.

ConsoleTerminal ( int histsize ) : System

Initializes a new instance of the ConsoleTerminal class.

Edit ( string prompt, string initial ) : string

Starts the console editing.

ReadCommand ( ) : CommandCall

Reads a command from the terminal.

ResetColor ( ) : void

Resets the foreground and background color of the terminal.

StopReading ( ) : void

Stops to read a command from the terminal if it is reading at the moment.

Write ( string text ) : void

Writes the given text to the terminal.

WriteLine ( ) : void

Writes a linebreak to the terminal.

WriteLine ( string line ) : void

Writes a complete line and appends a linebreak at the end.

Private Methods

Method Description
Clear ( ) : void
CmdBackspace ( ) : void
CmdBackwardWord ( ) : void
CmdDebug ( ) : void
CmdDeleteBackword ( ) : void
CmdDeleteChar ( ) : void
CmdDeleteWord ( ) : void
CmdDone ( ) : void
CmdEnd ( ) : void
CmdForwardWord ( ) : void
CmdHistoryNext ( ) : void
CmdHistoryPrev ( ) : void
CmdHome ( ) : void
CmdKillToEOF ( ) : void
CmdLeft ( ) : void
CmdRefresh ( ) : void
CmdReverseSearch ( ) : void
CmdRight ( ) : void
CmdTabOrComplete ( ) : void
CmdYank ( ) : void
ComputeRendered ( ) : void
EditLoop ( ) : void
ForceCursor ( int newpos ) : void
HandleChar ( char c ) : void
HistoryUpdateLine ( ) : void
InitText ( string initial ) : void
InsertChar ( char c ) : void
InsertTextAtCursor ( string str ) : void
InterruptEdit ( object sender, ConsoleCancelEventArgs a ) : void
Render ( ) : void
RenderAfter ( int p ) : void
RenderFrom ( int pos ) : void
ReverseSearch ( ) : void
SearchAppend ( char c ) : void
SetPrompt ( string newprompt ) : void
SetSearchPrompt ( string s ) : void
SetText ( string newtext ) : void
TextToRenderPos ( int pos ) : int
TextToScreenPos ( int pos ) : int
UpdateCursor ( int newpos ) : void
UpdateHomeRow ( int screenpos ) : void
WordBackward ( int p ) : int
WordForward ( int p ) : int
WriteWaitingRequests ( ) : void

Method Details

ConsoleTerminal() public method

Initializes a new instance of the ConsoleTerminal class.
public ConsoleTerminal ( ) : System
return System

ConsoleTerminal() public method

Initializes a new instance of the ConsoleTerminal class.
public ConsoleTerminal ( int histsize ) : System
histsize int The size of the command history.
return System

Edit() public method

Starts the console editing.
public Edit ( string prompt, string initial ) : string
prompt string The prompt in front of the edit space.
initial string The text, that should be shown at the beginning.
return string

ReadCommand() public method

Reads a command from the terminal.
public ReadCommand ( ) : CommandCall
return CommandCall

ResetColor() public method

Resets the foreground and background color of the terminal.
public ResetColor ( ) : void
return void

StopReading() public method

Stops to read a command from the terminal if it is reading at the moment.
public StopReading ( ) : void
return void

Write() public method

Writes the given text to the terminal.
public Write ( string text ) : void
text string The text to write.
return void

WriteLine() public method

Writes a linebreak to the terminal.
public WriteLine ( ) : void
return void

WriteLine() public method

Writes a complete line and appends a linebreak at the end.
public WriteLine ( string line ) : void
line string The line to write.
return void