Class ColoredGlyph
Represents an individual piece of a ICellSurface containing a glyph, foreground color, background color, and a mirror effect.
Inherited Members
Namespace: SadConsole
Assembly: SadConsole.dll
Syntax
public class ColoredGlyph : ColoredGlyphBase, IMatchable<ColoredGlyphBase>, IMatchable<ColoredGlyph>
Constructors
ColoredGlyph()
Creates a cell with a white foreground, black background, glyph 0, and no mirror effect.
Declaration
public ColoredGlyph()
ColoredGlyph(Color)
Creates a cell with the specified foreground, black background, glyph 0, and no mirror effect.
Declaration
public ColoredGlyph(Color foreground)
Parameters
Type | Name | Description |
---|---|---|
Color | foreground | Foreground color. |
ColoredGlyph(Color, Color)
Creates a cell with the specified foreground, specified background, glyph 0, and no mirror effect.
Declaration
public ColoredGlyph(Color foreground, Color background)
Parameters
ColoredGlyph(Color, Color, int)
Creates a cell with the specified foreground, background, and glyph, with no mirror effect.
Declaration
public ColoredGlyph(Color foreground, Color background, int glyph)
Parameters
Type | Name | Description |
---|---|---|
Color | foreground | Foreground color. |
Color | background | Background color. |
int | glyph | The glyph index. |
ColoredGlyph(Color, Color, int, Mirror)
Creates a cell with the specified foreground, background, glyph, and mirror effect.
Declaration
public ColoredGlyph(Color foreground, Color background, int glyph, Mirror mirror)
Parameters
Type | Name | Description |
---|---|---|
Color | foreground | Foreground color. |
Color | background | Background color. |
int | glyph | The glyph index. |
Mirror | mirror | The mirror effect. |
ColoredGlyph(Color, Color, int, Mirror, bool)
Creates a cell with the specified foreground, background, glyph, mirror, and visibility.
Declaration
public ColoredGlyph(Color foreground, Color background, int glyph, Mirror mirror, bool isVisible)
Parameters
Type | Name | Description |
---|---|---|
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. |
ColoredGlyph(Color, Color, int, Mirror, bool, List<CellDecorator>)
Creates a cell with the specified foreground, background, glyph, mirror effect, visibility and decorators.
Declaration
public ColoredGlyph(Color foreground, Color background, int glyph, Mirror mirror, bool isVisible, List<CellDecorator> decorators)
Parameters
Type | Name | Description |
---|---|---|
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. |
List<CellDecorator> | decorators | Decorators for the cell. |
Methods
Clear()
Resets the foreground, background, glyph, mirror effect and decorators.
Declaration
public override void Clear()
Overrides
Clone()
Returns a new cell with the same properties as this one.
Declaration
public override ColoredGlyphBase Clone()
Returns
Type | Description |
---|---|
ColoredGlyphBase | The new cell. |
Overrides
Matches(ColoredGlyph?)
Checks if this ColoredGlyph object's properties match another's.
Declaration
public bool Matches(ColoredGlyph? other)
Parameters
Type | Name | Description |
---|---|---|
ColoredGlyph | other | The other object to check. |