pike.git / lib / modules / _Image_XCF.pmod

version» Context lines:

pike.git/lib/modules/_Image_XCF.pmod:223:    array(Channel) channels = ({}); // unspecified order, really    array(Guide) guides = ({});    array(Parasite) parasites = ({});    array(Path) paths = ({});       Layer active_layer;    Channel active_channel;    Channel selection;       -  static string read_point_bz1( string data, Path path ) +  protected string read_point_bz1( string data, Path path )    {    object p = PathPoint( );    int x, y;    sscanf(data, "%4c%4c%4c%s", p->type, x, y, data);    SIGNED(x);    SIGNED(y);    p->x = (float)x;    p->y = (float)y;    return data;    }    -  static string read_point_bz2( string data, Path path ) +  protected string read_point_bz2( string data, Path path )    {    object p = PathPoint( );    sscanf(data, "%4c%4F%4F%s", p->type, p->x, p->y, data);    return data;    }    -  static string decode_one_path( string data, Path path ) +  protected string decode_one_path( string data, Path path )    {    int nlen, version, num_points;    sscanf(data, "%4c", nlen );    path->name = data[..nlen-2];    data = data[nlen..];    sscanf(data, "%4c%4c%4c%4c%4c",    path->locked, path->state, path->closed, num_points, version);    switch(version)    {    case 1:
pike.git/lib/modules/_Image_XCF.pmod:608:   }      // --- Encoding      #if 0      #define PROP(X,Y) sprintf("%4c%4c%s", PROP_##X, sizeof(Y), (Y))   #define UINT(X) sprintf("%4c", (X))   #define STRING(X) sprintf("%4c%s\0", sizeof(X)+1, (X))    - static string make_hiearchy(Image.Image img) { + protected string make_hiearchy(Image.Image img) {    string data = "";    data += UINT(img->xsize());    data += UINT(img->ysize());    data += UINT(3); // rgb       // Make just one tile    string i = (string)img;    string tile = "";    tile += UINT(img->xsize());    tile += UINT(img->ysize());    tile += UINT(sizeof(i));    tile += i;       data += UINT(sizeof(tile));    data += tile;    return data;   }    - static int make_mode(string mode) { + protected int make_mode(string mode) {    switch(mode) {    case "normal": return NORMAL_MODE;    }    werror("Mode %O not supported in XCF.\n", mode);    return NORMAL_MODE;   }    - static string make_layer(Image.Image|Image.Layer img) { + protected string make_layer(Image.Image|Image.Layer img) {    string data = "";    data += UINT(img->xsize());    data += UINT(img->ysize());    data += UINT(1); // FIXME: layer type    if(img->get_misc_value)    data += STRING(img->get_misc_value("name"));    else    data += STRING(" ");       // Layer properties
pike.git/lib/modules/_Image_XCF.pmod:731:    // }    buf->add( UINT(0) );       // Channels    buf->add( UINT(0) );       return (string)buf;   }      #endif +