C# Class StdPaint.RasterFont

Defines an ASCII font using a matrix of boolean values.
Show file Open project: TheBerkin/StdPaint Class Usage Examples

Public Properties

Property Type Description
BasicSmall RasterFont

Public Methods

Method Description
Draw ( ConsoleBuffer buffer, string text, Point position, BufferBrush brush, Alignment alignment ) : void

Draws text to a buffer using the specified settings.

FromString ( string source ) : RasterFont

Converts a font definition string to a raster font.

RasterFont ( int cx, int cy ) : System

Creates an empty raster font of the specified dimensions.

Method Details

Draw() public method

Draws text to a buffer using the specified settings.
public Draw ( ConsoleBuffer buffer, string text, Point position, BufferBrush brush, Alignment alignment ) : void
buffer ConsoleBuffer The buffer to draw to.
text string The text to draw.
position Point The position of the text.
brush BufferBrush The brush to draw the text with.
alignment Alignment The alignment of the text relative to its position.
return void

FromString() public static method

Converts a font definition string to a raster font.
public static FromString ( string source ) : RasterFont
source string The string to get font data from.
return RasterFont

RasterFont() public method

Creates an empty raster font of the specified dimensions.
public RasterFont ( int cx, int cy ) : System
cx int The glyph width to use.
cy int The glyph height to use.
return System

Property Details

BasicSmall public static property

A built-in font.
public static RasterFont,StdPaint BasicSmall
return RasterFont