Skip to content

CellDecorator Struct

Decorates a cell with a colored glyph.

C#
[DataContract]
public readonly struct CellDecorator : IEquatable<CellDecorator>

Implements IEquatable<CellDecorator>

Creates a new decorator with the specified colors, glyph, visiblity, and mirror settings.

C#
public CellDecorator(Color color, int glyph, Mirror mirror)

color SadRogue.Primitives.Color
Foreground color.

glyph int
Glyph value.

mirror Mirror
Mirror setting.

An empty cell decorator.

C#
public static CellDecorator Empty { get; }

Foreground color of the decorator.

C#
[DataMember]
public Color Color { get; init; }

Glyph of the decorator.

C#
[DataMember]
public int Glyph { get; init; }

Mirror setting of the decorator.

C#
[DataMember]
public Mirror Mirror { get; init; }

Determines if this object has the same value as the other.

C#
public bool Equals(CellDecorator other)

other CellDecorator
The object to test against.

bool
True if the objects have the same values.

C#
public override bool Equals(object? obj)

obj object

bool

C#
public override int GetHashCode()

int