2 * DO NOT EDIT THIS FILE - it is generated by Glade.
20 lookup_widget (GtkWidget *widget,
21 const gchar *widget_name)
23 GtkWidget *parent, *found_widget;
27 if (GTK_IS_MENU (widget))
28 parent = gtk_menu_get_attach_widget (GTK_MENU (widget));
30 parent = widget->parent;
32 parent = g_object_get_data (G_OBJECT (widget), "GladeParentKey");
38 found_widget = (GtkWidget*) g_object_get_data (G_OBJECT (widget),
41 g_warning ("Widget not found: %s", widget_name);
45 /* This is an internally used function to create pixmaps. */
47 create_pixmap (GtkWidget *widget,
48 const gchar *filename)
53 if (!filename || !filename[0])
54 return gtk_image_new ();
56 pathname = gnome_program_locate_file (NULL, GNOME_FILE_DOMAIN_APP_PIXMAP,
57 filename, TRUE, NULL);
60 g_warning (_("Couldn't find pixmap file: %s"), filename);
61 return gtk_image_new ();
64 pixmap = gtk_image_new_from_file (pathname);
69 /* This is an internally used function to create pixmaps. */
71 create_pixbuf (const gchar *filename)
73 gchar *pathname = NULL;
77 if (!filename || !filename[0])
80 pathname = gnome_program_locate_file (NULL, GNOME_FILE_DOMAIN_APP_PIXMAP,
81 filename, TRUE, NULL);
85 g_warning (_("Couldn't find pixmap file: %s"), filename);
89 pixbuf = gdk_pixbuf_new_from_file (pathname, &error);
92 fprintf (stderr, "Failed to load pixbuf file: %s: %s\n",
93 pathname, error->message);
100 /* This is used to set ATK action descriptions. */
102 glade_set_atk_action_description (AtkAction *action,
103 const gchar *action_name,
104 const gchar *description)
108 n_actions = atk_action_get_n_actions (action);
109 for (i = 0; i < n_actions; i++)
111 if (!strcmp (atk_action_get_name (action, i), action_name))
112 atk_action_set_description (action, i, description);