def load_pixbuf(fname, size=0):
 image = gtk.Image()
 image.set_from_file(os.path.join(_pixmap_path, fname))
 image = image.get_pixbuf()
 if size:
  aspect = (float(image.get_height()) / image.get_width())
  image = image.scale_simple(size, int((aspect * size)), 2)
 return image

def load_pixbuf ( fname , size = 0 ) : image = gtk . Image ( ) image . set_from_file ( os . path . join ( _pixmap_path , fname ) ) image = image . get_pixbuf ( ) if size : aspect = ( float ( image . get_height ( ) ) / image . get_width ( ) ) image = image . scale_simple ( size , int ( ( aspect * size ) ) , 2 ) return image
load an image from a file as a pixbuf .