Struct ColoredGlyphState
A ColoredGlyphBase with state information.
Inherited Members
Namespace: SadConsole
Assembly: SadConsole.dll
Syntax
public readonly struct ColoredGlyphState
Constructors
ColoredGlyphState(CellDecorator[], Color, Color, int, Mirror, bool)
Creates a new state.
Declaration
[JsonConstructor]
public ColoredGlyphState(CellDecorator[] decorators, Color foreground, Color background, int glyph, Mirror mirror, bool isVisible)
Parameters
Type | Name | Description |
---|---|---|
CellDecorator[] | decorators | Decorators for the cell. |
Color | foreground | Foreground color. |
Color | background | Background color. |
int | glyph | The glyph index. |
Mirror | mirror | The mirror effect. |
bool | isVisible | The visibility of the glyph. |
ColoredGlyphState(ColoredGlyphBase)
Creates a new state from a cell.
Declaration
public ColoredGlyphState(ColoredGlyphBase cell)
Parameters
Type | Name | Description |
---|---|---|
ColoredGlyphBase | cell | The colored glyph this state is a copy of. |
Properties
Background
A copy of the Background property.
Declaration
public Color Background { get; }
Property Value
Type | Description |
---|---|
Color |
Decorators
A copy of the Decorators property.
Declaration
public CellDecorator[] Decorators { get; }
Property Value
Type | Description |
---|---|
CellDecorator[] |
Foreground
A copy of the Foreground property.
Declaration
public Color Foreground { get; }
Property Value
Type | Description |
---|---|
Color |
Glyph
A copy of the Glyph property.
Declaration
public int Glyph { get; }
Property Value
Type | Description |
---|---|
int |
IsVisible
A copy of the IsVisible property.
Declaration
public bool IsVisible { get; }
Property Value
Type | Description |
---|---|
bool |
Mirror
A copy of the Mirror property.
Declaration
public Mirror Mirror { get; }
Property Value
Type | Description |
---|---|
Mirror |
Methods
RestoreState(ref ColoredGlyphBase)
Restores this state to the specified cell.
Declaration
public void RestoreState(ref ColoredGlyphBase cell)
Parameters
Type | Name | Description |
---|---|---|
ColoredGlyphBase | cell |