C# Класс SadConsole.Cell

Наследование: ICellAppearance
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание

Открытые методы

Метод Описание
Cell ( ) : System.Runtime.Serialization
Copy ( Cell destination ) : void

Copies this cells information to a new cell. Preserves appearance, Actual* properties, and glyph information.

CopyAppearanceTo ( ICellAppearance destination ) : void

Applies this appearance instance values to the destination appearance.

OnCreated ( ) : void

This should be called by anything creating and configuring a cell on the console. Configure the cell (foreground, background, index etc) and then call this.

Render ( SpriteBatch batch, Point position, Point size, Font font ) : void

Draws a single cell using the specified SpriteBatch.

Render ( SpriteBatch batch, Rectangle drawingRectangle, Font font ) : void

Draws a single cell using the specified SpriteBatch.

Reset ( ) : void

Resets this cell with default values.

ToString ( ) : string

Returns a string representing the Actual* property values.

UpdateAndApplyEffect ( double elapsedTime ) : void

Updates and applies the P:SadConsole.Cell.Effect to this cell. WARNING: Do not use with TextSurface. This should only be called when the cell has a standalone effect that isn't managed by the TextSurface.

Описание методов

Cell() публичный Метод

public Cell ( ) : System.Runtime.Serialization
Результат System.Runtime.Serialization

Copy() публичный Метод

Copies this cells information to a new cell. Preserves appearance, Actual* properties, and glyph information.
public Copy ( Cell destination ) : void
destination Cell The cell to copy to.
Результат void

CopyAppearanceTo() публичный Метод

Applies this appearance instance values to the destination appearance.
public CopyAppearanceTo ( ICellAppearance destination ) : void
destination ICellAppearance The target of the appearance copy.
Результат void

OnCreated() публичный Метод

This should be called by anything creating and configuring a cell on the console. Configure the cell (foreground, background, index etc) and then call this.
public OnCreated ( ) : void
Результат void

Render() публичный Метод

Draws a single cell using the specified SpriteBatch.
public Render ( SpriteBatch batch, Point position, Point size, Font font ) : void
batch Microsoft.Xna.Framework.Graphics.SpriteBatch Rendering batch.
position Microsoft.Xna.Framework.Point Pixel position on the screen to render.
size Microsoft.Xna.Framework.Point Rendering size of the cell.
font Font Font used to draw the cell.
Результат void

Render() публичный Метод

Draws a single cell using the specified SpriteBatch.
public Render ( SpriteBatch batch, Rectangle drawingRectangle, Font font ) : void
batch Microsoft.Xna.Framework.Graphics.SpriteBatch Rendering batch.
drawingRectangle Microsoft.Xna.Framework.Rectangle Where on the sreen to draw the cell, in pixels.
font Font Font used to draw the cell.
Результат void

Reset() публичный Метод

Resets this cell with default values.
public Reset ( ) : void
Результат void

ToString() публичный Метод

Returns a string representing the Actual* property values.
public ToString ( ) : string
Результат string

UpdateAndApplyEffect() публичный Метод

Updates and applies the P:SadConsole.Cell.Effect to this cell. WARNING: Do not use with TextSurface. This should only be called when the cell has a standalone effect that isn't managed by the TextSurface.
public UpdateAndApplyEffect ( double elapsedTime ) : void
elapsedTime double
Результат void