Class ConsoleFormatting
Text formatting tools for the console
Inheritance
object
ConsoleFormatting
Namespace: Terminaux.Base.Extensions
Assembly: Terminaux.dll
Syntax
public static class ConsoleFormatting
Properties
| Edit this page View SourceCurrentFormatting
Current text formatting
Declaration
public static ConsoleFormattingType CurrentFormatting { get; }
Property Value
| Type | Description |
|---|---|
| ConsoleFormattingType |
TextFormatted
Has the text been formatted?
Declaration
public static bool TextFormatted { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Methods
| Edit this page View SourceGetFormattingSequences(ConsoleFormattingType)
Gets the formatting sequences for the selected formatting types
Declaration
public static string GetFormattingSequences(ConsoleFormattingType types)
Parameters
| Type | Name | Description |
|---|---|---|
| ConsoleFormattingType | types | Selected formatting types |
Returns
| Type | Description |
|---|---|
| string | A string containing necessary VT sequences for all selected text formatting |
ResetFormatting()
Resets console text formatting
Declaration
public static void ResetFormatting()
SetFormatting(ConsoleFormattingType)
Sets text formatting for future plain writes
Declaration
public static void SetFormatting(ConsoleFormattingType formattings)
Parameters
| Type | Name | Description |
|---|---|---|
| ConsoleFormattingType | formattings | All text formatting to use |