pike.git / src / post_modules / GTK2 / source / gtkicontheme.pre

version» Context lines:

pike.git/src/post_modules/GTK2/source/gtkicontheme.pre:25:   //! directly in one of the elements of path, then that image will be used for   //! the icon name. (This is a legacy feature, and new icons should be put into   //! the default icon theme, which is called DEFAULT_THEME_NAME, rather than   //! directly on the icon path.)   {    pgtk2_verify_inited();    {    struct array *a;    const gchar **path;    int i,num; -  get_all_args("set_search_path",args,"%A",&a); +  get_all_args(NULL,args,"%A",&a);    if (a==NULL || a->size<1)    Pike_error("Invalid array.\n");    path=(const gchar **)g_malloc(sizeof(const gchar *)*a->size);    if (path==NULL)    SIMPLE_OUT_OF_MEMORY_ERROR("set_search_path",sizeof(const gchar *)*a->size);    for (i=num=0; i<a->size; i++) {    if (TYPEOF(ITEM(a)[i]) != PIKE_T_STRING)    continue;    path[num++]=(const gchar *)STR0((ITEM(a)+i)->u.string);    }
pike.git/src/post_modules/GTK2/source/gtkicontheme.pre:82:   GTK2.IconInfo lookup_icon(string name, int size, int flags)   //! Looks up a named icon and returns an object containing information such as   //! the filename of the icon. The icon can then be rendered into a pixbuf   //! using GTK2.IconInfo->load_icon().   {    pgtk2_verify_inited();    {    char *name;    INT_TYPE size,flags;    GtkIconInfo *gi; -  get_all_args("lookup_icon",args,"%s%i%i",&name,&size,&flags); +  get_all_args(NULL,args,"%s%i%i",&name,&size,&flags);    gi=gtk_icon_theme_lookup_icon(GTK_ICON_THEME(THIS->obj),name,size,flags);    pgtk2_pop_n_elems(args);    if (gi)    push_pgdk2object(gi,pgtk2_icon_info_program,1);    else    push_int(0);    }   }      GDK2.Pixbuf load_icon(string name, int size, int flags)   //! Looks up an icon in an icon theme, scales it to the given size and renders   //! it into a pixbuf.   {    pgtk2_verify_inited();    {    GdkPixbuf *pixbuf;    char *name;    INT_TYPE size,flags; -  get_all_args("load_icon",args,"%s%i%i",&name,&size,&flags); +  get_all_args(NULL,args,"%s%i%i",&name,&size,&flags);    pixbuf=gtk_icon_theme_load_icon(GTK_ICON_THEME(THIS->obj),name,size,flags,NULL);    pgtk2_pop_n_elems(args);    push_gobject(pixbuf);    }   }      array(string) list_icons(?string context)   //! Lists the icons in the current icon theme. Only a subset of the icons can   //! be listed by providing a context string. The set of values for the   //! context string is system dependent, but will typically include such values   //! as 'apps' and 'mimetypes'.   {    pgtk2_verify_inited();    {    char *context=NULL;    GList *gl,*g2;    int i = 0;    if (args) -  get_all_args("list_icons",args,"%s",&context); +  get_all_args(NULL,args,"%s",&context);    gl=g2=gtk_icon_theme_list_icons(GTK_ICON_THEME(THIS->obj),context);    pgtk2_pop_n_elems(args);    while (g2) {    PGTK_PUSH_GCHAR(g2->data);    g_free(g2->data);    i++;    g2=g_list_next(g2);    }    f_aggregate(i);    g_list_free(gl);
pike.git/src/post_modules/GTK2/source/gtkicontheme.pre:145:   array(int) get_icon_sizes(string name)   //! Returns an array of integers describing the sizes at which the icon is   //! available without scaling. A size of -1 means that the icon is available   //! in a scalable format.   {    pgtk2_verify_inited();    {    char *name;    gint *gt,*g2;    int i=0; -  get_all_args("get_icon_sizes",args,"%s",&name); +  get_all_args(NULL,args,"%s",&name);    gt=g2=gtk_icon_theme_get_icon_sizes(GTK_ICON_THEME(THIS->obj),name);    pgtk2_pop_n_elems(args);    while (g2) {    PGTK_PUSH_INT(*g2);    g2++;    i++;    }    f_aggregate(i);    g_free(gt);    }