pike.git / src / modules / Image / font.c

version» Context lines:

pike.git/src/modules/Image/font.c:1: - /* $Id: font.c,v 1.66 2000/12/01 08:10:00 hubbe Exp $ */ + /* $Id: font.c,v 1.67 2002/10/17 21:06:47 anders Exp $ */   #include "global.h"      #define SPACE_CHAR 'i'      extern unsigned char * image_default_font;   #define IMAGE_DEFAULT_FONT_SIZE 30596      /*   **! module Image   **! note - **! $Id: font.c,v 1.66 2000/12/01 08:10:00 hubbe Exp $ + **! $Id: font.c,v 1.67 2002/10/17 21:06:47 anders Exp $   **! class Font   **!   **! note   **! Short technical documentation on a font file:   **! This object adds the text-drawing and -creation   **! capabilities of the <ref>Image</ref> module.   **!   **! For simple usage, see   **! <ref>write</ref> and <ref>load</ref>.   **!
pike.git/src/modules/Image/font.c:778:    }       for (j=0; j<args; j++)    {    int max;    p_wchar0 *to_write0;    p_wchar1 *to_write1;    p_wchar2 *to_write2;    ptrdiff_t to_write_len;    if (sp[j-args].type!=T_STRING) -  bad_arg_error("font->write",sp-args,args,0,"",sp-args, -  "Bad arguments to font->write()\n"); +  bad_arg_error("font->text_extents",sp-args,args,0,"",sp-args, +  "Bad arguments to font->text_extents()\n");       xsize = max = 1;    to_write_len = sp[j-args].u.string->len;    switch(sp[j-args].u.string->size_shift)    {    case 0:    to_write0 = STR0(sp[j-args].u.string);    for (i = 0; i < to_write_len; i++)    {    if (xsize+char_width(THIS,to_write0[i]) > max)