Roxen.git / server / font_handlers / imagedir.pike

version» Context lines:

Roxen.git/server/font_handlers/imagedir.pike:1:   #include <config.h>   #include <stat.h> - constant cvs_version = "$Id: imagedir.pike,v 1.9 2001/01/02 18:56:35 nilsson Exp $"; + constant cvs_version = "$Id: imagedir.pike,v 1.10 2001/01/04 10:00:12 nilsson Exp $";      constant name = "Image directory fonts";   constant doc = ("Handles a directory with images (in almost any format), each "    "named after the character they will represent. Characters "    "with codes larger than 127 or less than 48 are encoded like "    "0xHEX where HEX is the code in hexadecimal. There must be a "    "file named 'fontname' in the directory, the first line of "    "that file is used as the name of the font");      inherit FontHandler;
Roxen.git/server/font_handlers/imagedir.pike:224:    if( font_list[ name ] )    return ({ "nn" });   }      Font open( string name, int size, int bold, int italic )   {   #ifdef THREADS    object key = lock->lock();   #endif    if( !font_list ) update_font_list(); +  int xpad,ypad; +  if(meta_data && meta_data[name]) { +  xpad = meta_data[name]->xpad; +  ypad = meta_data[name]->ypad; +  }    if( font_list[ name ] )    return myFont( font_list[name], size, -  meta_data[name]->xpad, meta_data[name]->ypad ); +  xpad, ypad );   }         void create()   {    roxen.getvar( "font_dirs" )    ->add_changed_callback( lambda(Variable.Variable v){    font_list = 0;    } );   }