Class TuiFramedRadio
- Namespace
- AshConsoleGraphics.Interactive
- Assembly
- AshConsoleGraphics.dll
Radio button: two options, either one or the other
public class TuiFramedRadio : TuiSelectable
- Inheritance
-
TuiFramedRadio
- Inherited Members
Constructors
TuiFramedRadio(char, char, string, string, Placement, int, int, CharFormat?, CharFormat?, CharFormat?, CharFormat?)
Initializes a new radio button with default frame chars ('┌┐└┘──││') and the same colors for selected and not selected
public TuiFramedRadio(char u, char c, string lo, string ro, Placement p, int x, int y, CharFormat? ff = null, CharFormat? cf = null, CharFormat? tf = null, CharFormat? pf = null)
Parameters
ucharUnchecked char
ccharChecked char
lostringLeft option
rostringRight option
pPlacementxintyintffCharFormatFrame format
cfCharFormatCheck format
tfCharFormatText format
pfCharFormatSelector format
TuiFramedRadio(char, char, string, string, Placement, int, int, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?)
Initializes a new radio button with default frame chars ('┌┐└┘──││')
public TuiFramedRadio(char u, char c, string lo, string ro, Placement p, int x, int y, CharFormat? ff, CharFormat? sff, CharFormat? cf, CharFormat? scf, CharFormat? tf, CharFormat? stf, CharFormat? pf)
Parameters
ucharUnchecked char
ccharChecked char
lostringLeft option
rostringRight option
pPlacementxintyintffCharFormatNot selected frame format
sffCharFormatSelected frame format
cfCharFormatNot selected check format
scfCharFormatSelected check format
tfCharFormatNot selected text format
stfCharFormatSelected text format
pfCharFormatSelector format
TuiFramedRadio(string, char, char, string, string, Placement, int, int, CharFormat?, CharFormat?, CharFormat?, CharFormat?)
Initializes a new radio button with the same colors when selected and when not
public TuiFramedRadio(string chars, char u, char c, string lo, string ro, Placement p, int x, int y, CharFormat? ff = null, CharFormat? cf = null, CharFormat? tf = null, CharFormat? pf = null)
Parameters
charsstringFrame charchters
ucharUnchecked char
ccharChecked char
lostringLeft option
rostringRight option
pPlacementxintyintffCharFormatFrame format
cfCharFormatCheck format
tfCharFormatText format
pfCharFormatSelector format
TuiFramedRadio(string, char, char, string, string, Placement, int, int, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?, CharFormat?)
Initializes a new radio button
public TuiFramedRadio(string chars, char u, char c, string lo, string ro, Placement p, int x, int y, CharFormat? ff, CharFormat? sff, CharFormat? cf, CharFormat? scf, CharFormat? tf, CharFormat? stf, CharFormat? pf)
Parameters
charsstringFrame charchters
ucharUnchecked char
ccharChecked char
lostringLeft option
rostringRight option
pPlacementxintyintffCharFormatNot selected frame format
sffCharFormatSelected frame format
cfCharFormatNot selected check format
scfCharFormatSelected check format
tfCharFormatNot selected text format
stfCharFormatSelected text format
pfCharFormatSelector format
Properties
CheckFormat
Not selected check charachter format
public CharFormat? CheckFormat { get; set; }
Property Value
CheckedChar
Check carachter when the checkbox is checked
public char CheckedChar { get; set; }
Property Value
FrameChars
Frame charachters. An example would be '┌┐└┘──││'
public char[] FrameChars { get; set; }
Property Value
- char[]
FrameFormat
Not selected frame charachter format
public CharFormat? FrameFormat { get; set; }
Property Value
LeftOption
Left option
public string LeftOption { get; set; }
Property Value
RightOption
Right option
public string RightOption { get; set; }
Property Value
RightOptionChecked
If the right option is checked(true) or the left one(false)
public bool RightOptionChecked { get; set; }
Property Value
SelectedCheckFormat
Selected check charachter format
public CharFormat? SelectedCheckFormat { get; set; }
Property Value
SelectedFrameFormat
Selected frame charachter format
public CharFormat? SelectedFrameFormat { get; set; }
Property Value
SelectedTextFormat
Selected text charachter format
public CharFormat? SelectedTextFormat { get; set; }
Property Value
SelectorFormat
Format of the selectors that surround the element when selcted
public CharFormat? SelectorFormat { get; set; }
Property Value
TextFormat
Not selected text charachter format
public CharFormat? TextFormat { get; set; }
Property Value
UnCheckedChar
Check carachter when the checkbox is unchecked
public char UnCheckedChar { get; set; }
Property Value
Methods
BufferNeedsToBeGenerated()
In most cases, the base implementation is enough
protected override bool BufferNeedsToBeGenerated()
Returns
GenerateBuffer()
The method that generates the element's buffer
protected override Buffer GenerateBuffer()