From f8de91ae41929286b1cf43c72093e5c996b1f949 Mon Sep 17 00:00:00 2001 From: Ian C Date: Sun, 18 Sep 2005 19:19:36 +0000 Subject: Added documentation --- bitmapfont.mod/doc/commands.html | 43 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 bitmapfont.mod/doc/commands.html (limited to 'bitmapfont.mod/doc/commands.html') diff --git a/bitmapfont.mod/doc/commands.html b/bitmapfont.mod/doc/commands.html new file mode 100644 index 0000000..d196db5 --- /dev/null +++ b/bitmapfont.mod/doc/commands.html @@ -0,0 +1,43 @@ + + +BlitzMax Module Reference + + + +

Type Reference

+

+
Type TBitmapFont Defines a bitmap font

The TBitmapFont object works from BMF Files, which are created using a tool called BitmapFontEd available at +http://www.noddybox.demon.co.uk/free/index-csharp.html
+Note that when colours are referenced they simply modify the colours in the font images as SetColor() would do on a norml image.
+When drawing characters the current scale, alpha and rotation settings are applied.


+
Method DrawColoured( txt:String, x:Int, y:Int, red:Int, green:Int, blue:Int ) Draws coloured text.

Draws txt at the supplied x,y co-ordinates. red,green and blue control the colour.



+

+
Method Draw( txt:String, x:Int, y:Int ) Draws white text.

Draws txt at the supplied x,y co-ordinates in white.



+

+
Method CentreColoured( txt:String, y:Int, red:Int, green:Int, blue:Int ) Draws centred, coloured text.

Draws txt centred at the supplied y co-ordinate. red,green and blue control the colour.



+

+
Method Centre( txt:String, y:Int ) Draws centred, white text.

Draws txt centred at the supplied y co-ordinate in white.



+

+
Method TextWidth:Int( txt:String ) Width of the supplied string.

Returns: The length of the string txt in pixels.

The current scale settings are taken into account.



+

+
Method TextHeight:Int( txt:String ) Height of the supplied string.

Returns: The height of the string txt in pixels.

The current scale settings are taken into account.



+

+
Method MaxWidth:Int() Width of the largest character.

Returns: The width in pixels of the largest character in the font.



+

+
Method MaxHeight:Int() Height of the largest character.

Returns: The height in pixels of the largest character in the font.



+

+
Function Load:TBitmapFont( path:String, image_flags:Int ) Loads a font from the supplied BMF file.

Returns: The created font, or null if the BMF file couldn't be loaded.

The image_flags are passed onto CreateImage() when the images for the font are being created.



+

+

Module Information

+ + + + + + + + + +
Framework Simple Bitmap Font Routines
Copyright Public Domain
Author Ian Cowburn
Version $Revision$
+ + -- cgit v1.2.3