#include "gfxfont.h"
#include "gfxcore.h"
#include "misc.h"
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <assert.h>
#include <mem.h>
#include <dos.h>
Go to the source code of this file.
Functions | |
Font * | GFX_LoadFont (char *fn) |
Load a Font from disk. | |
void | GFX_FreeFont (Font *font) |
Free a Font. | |
int | printScratch (char *bmBits, Font *font, char *string) |
Print a string into scratch memory. | |
int | GFX_Print (Graphics *gfx, char *string) |
int | GFX_PrintAt (Graphics *gfx, int x, int y, char *string) |
Print text at position (x,y). | |
int | GFX_Printf (Graphics *gfx, char *format,...) |
Print a formatted text string. | |
int | GFX_PrintfAt (Graphics *gfx, int x, int y, char *format,...) |
Print formatted text at position (x,y). | |
int | GFX_TextWidth (Graphics *gfx, char *string) |
Get width of text. | |
Variables | |
char | printfbuf [256] |
|
Free a Font.
Definition at line 85 of file gfxfont.cpp. References font. |
|
Load a Font from disk.
Definition at line 38 of file gfxfont.cpp. References Font::firstChar, font, FONT_MAGIC, Font::height, Font::maxWidth, and Font::numChars. Referenced by main(). |
|
Definition at line 180 of file gfxfont.cpp. References Graphics::bitmap, Graphics::blitMode, BM_Blit(), Graphics::font, Font::height, printScratch(), Graphics::x, and Graphics::y. Referenced by GFX_PrintAt(), and GFX_Printf(). |
|
Print text at position (x,y). The cursor position isn't changed by this function.
Definition at line 207 of file gfxfont.cpp. References GFX_Print(), swap(), width, Graphics::x, and Graphics::y. Referenced by GFX_PrintfAt(), and gfxTest(). |
|
Print a formatted text string. The cursor position is advanced to the end of the string.
Definition at line 225 of file gfxfont.cpp. |
|
Print formatted text at position (x,y). The cursor position isn't changed by this function.
Definition at line 251 of file gfxfont.cpp. References GFX_PrintAt(), printfbuf, and width. Referenced by gfxTest(). |
|
Get width of text. Return the width of the string in pixels, as it would be returned by GFX_Print().
Definition at line 277 of file gfxfont.cpp. References Font::firstChar, font, Graphics::font, Font::numChars, Font::offsets, and width. |
|
Print a string into scratch memory.
Definition at line 101 of file gfxfont.cpp. References bmBits, font, Font::numPages, and pages. Referenced by GFX_Print(). |
|
Definition at line 28 of file gfxfont.cpp. Referenced by GFX_Printf(), and GFX_PrintfAt(). |