Interface ICellSurface
An array of ColoredGlyphBase objects used to represent a 2D surface.
Inherited Members
Namespace: SadConsole
Assembly: SadConsole.dll
Syntax
public interface ICellSurface : IGridView<ColoredGlyphBase>, IEnumerable<ColoredGlyphBase>, IEnumerable, ISurface
Properties
Area
Returns a rectangle that represents the entire size of the surface.
Declaration
Rectangle Area { get; }
Property Value
Type | Description |
---|---|
Rectangle |
Connected3dBox
Glyph indexes for a block box that looks 3d.
Declaration
public static int[] Connected3dBox { get; }
Property Value
Type | Description |
---|---|
int[] |
ConnectedLineEmpty
Glyph indexes for an empty line 0.
Declaration
public static int[] ConnectedLineEmpty { get; }
Property Value
Type | Description |
---|---|
int[] |
ConnectedLineThick
Glyph indexes for a thick line.
Declaration
public static int[] ConnectedLineThick { get; }
Property Value
Type | Description |
---|---|
int[] |
ConnectedLineThin
Glyph indexes for a thin line.
Declaration
public static int[] ConnectedLineThin { get; }
Property Value
Type | Description |
---|---|
int[] |
ConnectedLineThinExtended
Glyph indexes for a thin line using a SadConsole extended font.
Declaration
public static int[] ConnectedLineThinExtended { get; }
Property Value
Type | Description |
---|---|
int[] |
DefaultBackground
The default background for glyphs on this surface.
Declaration
Color DefaultBackground { get; set; }
Property Value
Type | Description |
---|---|
Color |
DefaultForeground
The default foreground for glyphs on this surface.
Declaration
Color DefaultForeground { get; set; }
Property Value
Type | Description |
---|---|
Color |
DefaultGlyph
The default glyph used in clearing and erasing.
Declaration
int DefaultGlyph { get; set; }
Property Value
Type | Description |
---|---|
int |
Effects
Processes the effects added to cells with CellSurfaceEditor.SetEffect*.
Declaration
EffectsManager Effects { get; }
Property Value
Type | Description |
---|---|
EffectsManager |
IsDirty
Indicates the surface has changed and needs to be rendered.
Declaration
bool IsDirty { get; set; }
Property Value
Type | Description |
---|---|
bool |
IsScrollable
Declaration
bool IsScrollable { get; }
Property Value
Type | Description |
---|---|
bool |
TimesShiftedDown
A variable that tracks how many times this editor shifted the surface down.
Declaration
int TimesShiftedDown { get; set; }
Property Value
Type | Description |
---|---|
int |
TimesShiftedLeft
A variable that tracks how many times this editor shifted the surface left.
Declaration
int TimesShiftedLeft { get; set; }
Property Value
Type | Description |
---|---|
int |
TimesShiftedRight
A variable that tracks how many times this editor shifted the surface right.
Declaration
int TimesShiftedRight { get; set; }
Property Value
Type | Description |
---|---|
int |
TimesShiftedUp
A variable that tracks how many times this editor shifted the surface up.
Declaration
int TimesShiftedUp { get; set; }
Property Value
Type | Description |
---|---|
int |
UsePrintProcessor
When true, the Parser is used to generate a ColoredString before printing.
Declaration
bool UsePrintProcessor { get; set; }
Property Value
Type | Description |
---|---|
bool |
View
The visible portion of the surface.
Declaration
Rectangle View { get; set; }
Property Value
Type | Description |
---|---|
Rectangle |
ViewHeight
Gets or sets the visible height of the surface in cells.
Declaration
int ViewHeight { get; set; }
Property Value
Type | Description |
---|---|
int |
ViewPosition
The position of the view within the buffer.
Declaration
Point ViewPosition { get; set; }
Property Value
Type | Description |
---|---|
Point |
ViewWidth
Gets or sets the visible width of the surface in cells.
Declaration
int ViewWidth { get; set; }
Property Value
Type | Description |
---|---|
int |
Methods
CreateLine(int)
Creates an array of glyphs that can be used as a connected line.
Declaration
public static int[] CreateLine(int singleGlyph)
Parameters
Type | Name | Description |
---|---|---|
int | singleGlyph | The glyph to use for the connected line array. |
Returns
Type | Description |
---|---|
int[] | An array of glyphs. |
ValidateLineStyle<T>(in T[])
Returns a value that indicates a line style array is not null and contains the required number of elements.
Declaration
public static bool ValidateLineStyle<T>(in T[] connectedLineStyle)
Parameters
Type | Name | Description |
---|---|---|
T[] | connectedLineStyle | The array to check based on the ICellSurface.ConnectedLineIndex enum. |
Returns
Type | Description |
---|---|
bool | True when the line style is correct. |
Type Parameters
Name | Description |
---|---|
T | Type of the array. |
Events
IsDirtyChanged
An event that is raised when IsDirty changes.
Declaration
event EventHandler IsDirtyChanged
Event Type
Type | Description |
---|---|
EventHandler |