Roxen.git / server / modules / graphics / graphic_text.pike

version» Context lines:

Roxen.git/server/modules/graphics/graphic_text.pike:1: - string cvs_version="$Id: graphic_text.pike,v 1.50 1997/08/12 06:32:22 per Exp $"; + string cvs_version="$Id: graphic_text.pike,v 1.51 1997/08/12 19:45:43 per Exp $";      #include <module.h>   inherit "module";   inherit "roxenlib";      #if efun(_static_modules)   # define map_array Array.map   import Image;   # define Image image   # define Font font
Roxen.git/server/modules/graphics/graphic_text.pike:99:    });   }         array (string) list_fonts()   {    array fnts;    catch(fnts = get_dir("fonts/32/") - ({".",".."}));    if(!fnts)    { -  report_error("Failed to find any fonts in 'fonts/32/'. No default font.\n"); +     return ({});    }    return fnts;   }      void create()   {    defvar("deflen", 300, "Default maximum text-length", TYPE_INT|VAR_MORE,    "The module will, per default, not try to render texts "    "longer than this. This is a safeguard for things like "
Roxen.git/server/modules/graphics/graphic_text.pike:158:    if ((!name)||(name == "")) {    name = QUERY(default_size)+"/"+QUERY(default_font);    } else if(sscanf(name, "%*s/%*s") != 2) {    name=QUERY(default_size)+"/"+name;    }       name = "fonts/" + name;       if(!fnt->load( name ))    { -  report_error("Failed to load the font "+name+", using the default font.\n"); +  report_debug("Failed to load the compatibility font "+name+ +  ", using the default font.\n");    if(!fnt->load("fonts/"+QUERY(default_size) +"/"+ QUERY(default_font))) -  error("Failed to load the default font\n"); +  report_error("Failed to load the default compatibility font\n");    }    catch {    if(justification=="right") fnt->right();    if(justification=="center") fnt->center();    if(xs)fnt->set_x_spacing((100.0+(float)xs)/100.0);    if(ys)fnt->set_y_spacing((100.0+(float)ys)/100.0);    };    return fnt;   }