Méthode | Description | |
---|---|---|
BitmapFont ( string strFontFilename ) : System |
Create a new font from the info in the specified font descriptor (XML) file
|
|
DrawString ( Color color, string format ) : int |
Draw the given string using the specified color. The text drawing location is immediately after the last drawn text (default=0,0).
|
|
DrawString ( Vector2 vOrigin, Color color, string format ) : int |
Draw the given string at vOrigin using the specified color
|
|
DrawString ( int x, int y, Color color, string format ) : int |
Draw the given string at (x,y) using the specified color
|
|
DrawString ( int x, int y, string format ) : int |
Draw the given string at (x,y). The text color is inherited from the last draw command (default=White).
|
|
DrawString ( string format ) : int |
Draw the given string at (x,y). The text drawing location is immediately after the last drawn text (default=0,0). The text color is inherited from the last draw command (default=White).
|
|
MeasureString ( string format ) : int |
Calculate the width of the given string.
|
|
Reset ( GraphicsDevice device ) : void |
Reset the font when the device has changed
|
|
SetPen ( int x, int y ) : void |
Set the current pen position
|
Méthode | Description | |
---|---|---|
CalcKern ( char chLeft, char chRight ) : int |
Get the kern value for the given pair of characters
|
|
GetXMLAttribute ( |
Get the XML attribute value (without throwing if the attribute doesn't exist)
|
|
LoadFontXML ( |
Load the font data from an XML font descriptor file
|
|
LoadFontXML_bitmaps ( |
Load the data from the "bitmaps" node
|
|
LoadFontXML_font ( |
Load the data from the "font" node
|
|
LoadFontXML_glyphs ( |
Load the data from the "glyphs" node
|
|
LoadFontXML_kernpairs ( |
Load the data from the "kernpairs" node
|
public BitmapFont ( string strFontFilename ) : System | ||
strFontFilename | string | font file (.xml) |
Résultat | System |
public DrawString ( Color color, string format ) : int | ||
color | Color | Text color |
format | string | String format |
Résultat | int |
public DrawString ( Vector2 vOrigin, Color color, string format ) : int | ||
vOrigin | Vector2 | (x,y) coord |
color | Color | Text color |
format | string | String format |
Résultat | int |
public DrawString ( int x, int y, Color color, string format ) : int | ||
x | int | X-coord |
y | int | Y-coord |
color | Color | Text color |
format | string | String format |
Résultat | int |
public DrawString ( int x, int y, string format ) : int | ||
x | int | X-coord |
y | int | Y-coord |
format | string | String format |
Résultat | int |
public DrawString ( string format ) : int | ||
format | string | String format |
Résultat | int |
public MeasureString ( string format ) : int | ||
format | string | String format |
Résultat | int |
public Reset ( GraphicsDevice device ) : void | ||
device | GraphicsDevice | The new device |
Résultat | void |
public SetPen ( int x, int y ) : void | ||
x | int | X-coord |
y | int | Y-coord |
Résultat | void |