Rev 5499 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
3107 | leency | 1 | char fontinfo[28]; |
2 | |||
5515 | leency | 3 | dword libtruetype = #att_libtruetype; |
3107 | leency | 4 | |
5515 | leency | 5 | char att_libtruetype[22] = "/sys/lib/truetype.obj\0"; |
3107 | leency | 6 | |
5515 | leency | 7 | dword truetype = #att_truetype; // truetype(unsigned char *s, stbtt_fontinfo *buffer, char *screen1, int width, int height) |
8 | dword get_length = #att_get_length; // get_length(unsigned char *s, char *buffer, int height, int max_len) |
||
9 | dword get_width = #att_get_width; // get_width_utf8(unsigned char *s, stbtt_fontinfo *buffer, int height) |
||
10 | dword text_out = #att_text_out; // text_out(unsigned char *string, char *buffer, int height, int color,int back_color, int x, int y) |
||
11 | dword init_font = #att_init_font; // init_font(stbtt_fontinfo *font,unsigned char *FontData) |
||
12 | dword text_out_mem = #att_text_out_mem; // text_out_mem(unsigned char *string, stbtt_fontinfo *buffer, int height, int color,int back_color) |
||
13 | dword text_scale_EM = #att_text_scale; // scale_EM(stbtt_fontinfo *buffer, int size) |
||
3839 | Asper | 14 | $DD 2 dup 0 |
3107 | leency | 15 | |
5515 | leency | 16 | char att_truetype[] = "truetype"; |
17 | char att_get_length[] = "get_length"; |
||
18 | char att_get_width[] = "get_width"; |
||
19 | char att_text_out[] = "text_out"; |
||
20 | char att_init_font[] = "init_font"; |
||
21 | char att_text_out_mem[] = "text_out_mem"; |
||
22 | char att_text_scale[] = "scale_EM"; |
||
23 | |||
24 | //============================================================ |
||
25 | //============================================================ |
||
26 | |||
27 | struct stbtt_fontinfo |
||
28 | { |
||
29 | dword userdata; |
||
30 | dword data; // pointer to .ttf file |
||
31 | int fontstart; // offset of start of font |
||
32 | |||
33 | int numGlyphs; // number of glyphs, needed for range checking |
||
34 | |||
35 | int loca,head,glyf,hhea,hmtx,kern; // table locations as offset from start of .ttf |
||
36 | int index_map; // a cmap mapping for our chosen character encoding |
||
37 | int indexToLocFormat; // format needed to map from glyph index to glyph |
||
38 | }; |