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

version» Context lines:

pike.git/src/post_modules/GTK2/source/global.pre:69:    while(g_main_iteration( 0 ) );   #endif   }      static struct callback *backend_cb;   %}   void parse_rc(string rc)   //! Takes a string and reads it as a gtkrc file.   {    char *s; -  get_all_args("parse_rc",args,"%s",&s); +  get_all_args(NULL,args,"%s",&s);    gtk_rc_parse_string(s);    pgtk2_pop_n_elems(args);    push_int(0);   /* gtk_widget_propagate_default_style(); */   }      GDK2.Window root_window()   //! Returns the root window of the current display   {    static struct object *_pgtk_root_window;
pike.git/src/post_modules/GTK2/source/global.pre:348:   //! Always returns false.   {    pgtk2_pop_n_elems(args);    push_int(0);   }      void grab_add(GTK2.Widget widget)   //! Grab a widget.   {    struct object *o; -  get_all_args("grab_add",args,"%o",&o); +  get_all_args(NULL,args,"%o",&o);    gtk_grab_add(GTK_WIDGET(get_gobject(o)));    pgtk2_pop_n_elems(args);   }      void grab_remove(GTK2.Widget widget)   //! Remove the grab.   {    struct object *o; -  get_all_args("grab_remove",args,"%o",&o); +  get_all_args(NULL,args,"%o",&o);    gtk_grab_remove(GTK_WIDGET(get_gobject(o)));    pgtk2_pop_n_elems(args);   }         require x11;      /* Low-level X11 related functions */   %{   #ifdef HAVE_XDPMS
pike.git/src/post_modules/GTK2/source/global.pre:448:   void move_cursor_abs( GDK2.Window w, int dx, int dy )   //! Move the mouse-cursor to x,y, relative to the upper left corner of   //! the specified window. This will generate a normal motion event.   //!   //! Note that this is a low-level X11 function, and thus only works   //! when GDK uses X11.   {    INT_TYPE x, y;    struct object *o;    GdkWindow *w; -  get_all_args("move_cursor_abs",args,"%o%i%i",&o,&x,&y); +  get_all_args(NULL,args,"%o%i%i",&o,&x,&y);    w = GDK_WINDOW(get_gdkobject( o, window ));    if( !w )    Pike_error("No window specified!\n");    XWarpPointer(GDK_DISPLAY(),None,GDK_WINDOW_XWINDOW(w),0,0,0,0,x,y);    pgtk2_pop_n_elems(args);   }      endrequire; /* x11 */      require gtk22;
pike.git/src/post_modules/GTK2/source/global.pre:542:   mapping(string:mixed) get_file_info(string filename)   //! Parses an image file far enough to determine its format   //! and size.   {    GdkPixbufFormat *gpf;    gchar **gca;    int j,k;    char *filename;    int width,height;    -  get_all_args("get_file_info",args,"%s",&filename); +  get_all_args(NULL,args,"%s",&filename);    gpf=gdk_pixbuf_get_file_info(filename,&width,&height);    pgtk2_pop_n_elems(args);    k=0;       ref_push_string(_STR("name"));    PGTK_PUSH_GCHAR(gdk_pixbuf_format_get_name(gpf));    k++;       ref_push_string(_STR("description"));    PGTK_PUSH_GCHAR(gdk_pixbuf_format_get_description(gpf));
pike.git/src/post_modules/GTK2/source/global.pre:615:    k++;       f_aggregate_mapping(k*2);   }      void set_default_icon(GDK2.Pixbuf icon)   //! Sets an icon to be used as fallback for windows that haven't had set_icon()   //! called on them from a pixbuf.   {    struct object *o1; -  get_all_args("set_default_icon",args,"%o",&o1); +  get_all_args(NULL,args,"%o",&o1);    gtk_window_set_default_icon(GDK_PIXBUF(get_gobject(o1)));    pgtk2_pop_n_elems(args);   }   endrequire;      require gtk22;   void set_default_icon_from_file(string filename)   //! Sets an icon to be used as fallback for windows that haven't had   //! set_icon_list() called on them from a file on disk.   {    struct svalue *sv; -  get_all_args("set_default_icon_from_file",args,"%*",&sv); +  get_all_args(NULL,args,"%*",&sv);       gtk_window_set_default_icon_from_file(PGTK_GETSTR(sv),NULL);    pgtk2_pop_n_elems(args);   }   endrequire;         require gtk26;   void set_default_icon_name(string name)   //! Sets an icon to be as fallback for windows that haven't had set_icon_list()   //! called on them from a themed icon.   {    char *s; -  get_all_args("set_default_icon_name",args,"%s",&s); +  get_all_args(NULL,args,"%s",&s);    gtk_window_set_default_icon_name(s);    pgtk2_pop_n_elems(args);   }   endrequire;      array(GTK2.Widget) list_toplevels()   //! Returns a list of all existing toplevel windows.   {    GList *gl=gtk_window_list_toplevels();    GList *g2=gl;
pike.git/src/post_modules/GTK2/source/global.pre:690:   void set_default_icon_list(array(GDK2.Pixbuf) list)   //! Sets an icon list to be used as fallback for windows that haven't had   //! set_icon_list() called on them to set up a window-specific icon list. This   //! function allows you to set up the icon for all windows in your app at once.   {    GList *gl=NULL;    struct array *a;    int i;    GdkPixbuf *gp;    -  get_all_args("set_default_icon_list",args,"%A",&a); +  get_all_args(NULL,args,"%A",&a);    if (a==NULL)    SIMPLE_ARG_ERROR("set_default_icon_list",args,"Invalid array");    for (i=0; i<a->size; i++) {    if (TYPEOF(ITEM(a)[i]) != PIKE_T_OBJECT)    continue;    gp=GDK_PIXBUF(get_gobject((ITEM(a)+i)->u.object));    if (gp)    gl=g_list_append(gl,gp);    }    if (gl) {
pike.git/src/post_modules/GTK2/source/global.pre:715:   }      require gtk24;   void set_default_icon(GDK2.Pixbuf pix)   //! Sets an icon to be used as fallback for windows that haven't had   //! set_icon() called on them.   {    struct object *o1;    GdkPixbuf *gp;    -  get_all_args("set_default_icon",args,"%o",&o1); +  get_all_args(NULL,args,"%o",&o1);    gp=GDK_PIXBUF(get_gobject(o1));    if (gp)    gtk_window_set_default_icon(gp);    pgtk2_pop_n_elems(args);   }   endrequire;      require gtk22;   void set_default_icon_from_file(string filename)   //! Sets an icon to be used as fallback from a file on disk.   {    GError *err=NULL;    char *filename;    int res;    -  get_all_args("set_default_icon_from_file",args,"%s",&filename); +  get_all_args(NULL,args,"%s",&filename);    res=gtk_window_set_default_icon_from_file(filename,&err);    if (!res)    Pike_error("Unable to set icon from file %s: %s\n",filename,err->message);    pgtk2_pop_n_elems(args);   }   endrequire;      require gtk26;   void set_default_icon_name(string name)   //! Sets an icon to be used as fallback for windows that haven't had   //! set_icon_list() called on them from a named themed icon.   {    struct pike_string *t;    -  get_all_args("set_default_icon_name",args,"%T",&t); +  get_all_args(NULL,args,"%T",&t);    if (t) {    ref_push_string(t);    f_string_to_utf8(1);    gtk_window_set_default_icon_name(CGSTR0(Pike_sp[-1].u.string));    pop_stack();    }    pgtk2_pop_n_elems(args);   }   endrequire;   
pike.git/src/post_modules/GTK2/source/global.pre:781:   //! icons.   //! <p>   //! In general, if you use add_builtin_icon() you should also install the icon   //! in the icon theme, so that the icon is generally available.   {    pgtk2_verify_inited();    {    char *name;    INT_TYPE size;    struct object *o1; -  get_all_args("add_builtin_icon",args,"%s%i%o",&name,&size,&o1); +  get_all_args(NULL,args,"%s%i%o",&name,&size,&o1);    gtk_icon_theme_add_builtin_icon(name,size,GDK_PIXBUF(get_gobject(o1)));    }    pgtk2_pop_n_elems(args);   }   endrequire;      require gtk22;   void set_auto_startup_notification(int setting)   //! By default, after showing the first GTK2.Window for each GDK2.Screen,   //! GTK+ calls GDK2.Screen->notify_startup_complete(). Call this function to   //! disable the automatic startup notification. You might do this if your   //! first window is a splash screen, and you want to delay notification until   //! after your real main window has been shown, for example.   //! <p>   //! In that example, you would disable startup notification temporarily,   //! show your splash screen, then re-enable it so that showing the main   //! window would automatically result in notification.   {    INT_TYPE set;    -  get_all_args("set_auto_startup_notification",args,"%i",&set); +  get_all_args(NULL,args,"%i",&set);    gtk_window_set_auto_startup_notification(set);    pgtk2_pop_n_elems(args);   }   endrequire;      array(int) version()   //! Returns the version of the GTK library.   {    pop_n_elems(args);    push_int( gtk_major_version );