C# Class SadConsole.Cell

Inheritance: ICellAppearance
Afficher le fichier Open project: Thraka/SadConsole Class Usage Examples

Private Properties

Свойство Type Description

Méthodes publiques

Méthode Description
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.

Method Details

Cell() public méthode

public Cell ( ) : System.Runtime.Serialization
Résultat System.Runtime.Serialization

Copy() public méthode

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.
Résultat void

CopyAppearanceTo() public méthode

Applies this appearance instance values to the destination appearance.
public CopyAppearanceTo ( ICellAppearance destination ) : void
destination ICellAppearance The target of the appearance copy.
Résultat void

OnCreated() public méthode

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
Résultat void

Render() public méthode

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.
Résultat void

Render() public méthode

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.
Résultat void

Reset() public méthode

Resets this cell with default values.
public Reset ( ) : void
Résultat void

ToString() public méthode

Returns a string representing the Actual* property values.
public ToString ( ) : string
Résultat string

UpdateAndApplyEffect() public méthode

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
Résultat void