Index: gnome-panel/ChangeLog
===================================================================
RCS file: /cvs/gnome/gnome-panel/gnome-panel/ChangeLog,v
retrieving revision 1.1744
diff -r1.1744 ChangeLog
0a1,19
> 2002-05-15  Pier Luigi Fiorini  <plfiorini@supereva.it>
> 
> 	* gnome-panel-screenshot.c (delay_callback): Destroy the delay dialog,
> 	take a window or screen shot and show the window.
> 	* gnome-panel-screenshot.c (main): Added the options parameter that
> 	shows the delay dialog. Connected the destroy signal of toplevel to
> 	gtk_main_quit.
> 
> 2002-05-14  Pier Luigi Fiorini  <plfiorini@supereva.it>
> 
> 	* gnome-panel-screenshot.glade2: s/screenshot/screen shot/
> 	* gnome-panel-screenshot.glade2: Added the radio button
> 	"Take another screen shot" that shows a dialog which allow
> 	users to specify shot type (window or whole screen) and delay.
> 	* gnome-panel-screenshot.c (on_ok_button_clicked):
> 	If the "Take another screen shot" radio button is toggled,
> 	show the delay dialog.
> 	* gnome-panel-screenshot.c (take_shot): Take a window or whole screen shot.
> 
Index: gnome-panel/gnome-panel-screenshot.c
===================================================================
RCS file: /cvs/gnome/gnome-panel/gnome-panel/gnome-panel-screenshot.c,v
retrieving revision 1.30
diff -r1.30 gnome-panel-screenshot.c
31a32
> #include <gdk/gdkevents.h>
69a71,74
> static GtkWidget *delay_dialog = NULL;
> static gboolean window = FALSE;
> static guint delay = 0;
> static gboolean options = FALSE;
75a81
> static gint timeout;
77,79c83,85
< static GtkTargetEntry drag_types[] =
< 	{ { "x-special/gnome-icon-list", 0, 0 },
< 	  { "text/uri-list", 0, 0 } };
---
> static GtkTargetEntry drag_types[] = { {"x-special/gnome-icon-list", 0, 0},
> {"text/uri-list", 0, 0}
> };
82,91c88,101
< void on_save_rbutton_toggled (GtkWidget *toggle, gpointer data);
< void on_preview_expose_event (GtkWidget *drawing_area,
< 			      GdkEventExpose *event,
< 			      gpointer data);
< void on_preview_configure_event (GtkWidget *drawing_area,
< 				 GdkEventConfigure *event,
< 				 gpointer data);
< void on_ok_button_clicked (GtkWidget *widget, gpointer data);
< void on_cancel_button_clicked (GtkWidget *widget, gpointer data);
< int on_toplevel_key_press_event (GtkWidget *widget, GdkEventKey *key);
---
> static gboolean delay_callback (gpointer data);
> void on_save_rbutton_toggled (GtkWidget * toggle, gpointer data);
> void on_preview_expose_event (GtkWidget * drawing_area,
> 			      GdkEventExpose * event, gpointer data);
> void on_preview_configure_event (GtkWidget * drawing_area,
> 				 GdkEventConfigure * event, gpointer data);
> void on_ok_button_clicked (GtkWidget * widget, gpointer data);
> void on_cancel_button_clicked (GtkWidget * widget, gpointer data);
> int on_toplevel_key_press_event (GtkWidget * widget, GdkEventKey * key);
> void on_window_rbutton_toggled (GtkWidget * toggle, gpointer data);
> void on_screen_rbutton_toggled (GtkWidget * toggle, gpointer data);
> void on_delay_spin_value_changed (GtkWidget * spin, gpointer data);
> void on_delay_response (GtkWidget * dialog, gint response_id,
> 			gpointer data);
94c104,109
< static gchar * add_file_to_path (const gchar *path);
---
> static void setup_busy (gboolean busy);
> static gchar *add_file_to_path (const gchar * path);
> static void take_window_shot (void);
> static void take_screen_shot (void);
> static void take_shot (void);
> static void prompt_delay (void);
100c115
< save_to_file_internal (FILE *fp, const char *file, char **error)
---
> save_to_file_internal (FILE * fp, const char *file, char **error)
172c187
< 			memcpy (&(data[x*3]), &(ptr[x*3]), 3);
---
> 			memcpy (&(data[x * 3]), &(ptr[x * 3]), 3);
174c189
< 		row_ptr = (png_bytep)data;
---
> 		row_ptr = (png_bytep) data;
179,180c194,195
<        if (data)
<                free (data);
---
> 	if (data)
> 		free (data);
182,183c197,198
<        png_write_end (png_ptr, info_ptr);
<        png_destroy_write_struct (&png_ptr, (png_infopp) NULL);
---
> 	png_write_end (png_ptr, info_ptr);
> 	png_destroy_write_struct (&png_ptr, (png_infopp) NULL);
185c200
<        return TRUE;
---
> 	return TRUE;
198,204c213,218
< 			(GTK_WINDOW (toplevel),
< 			 0 /* flags */,
< 			 GTK_MESSAGE_QUESTION,
< 			 GTK_BUTTONS_YES_NO,
< 			 _("File %s already exists. Overwrite?"),
< 			 file);
< 		if (gtk_dialog_run (GTK_DIALOG (dialog)) != GTK_RESPONSE_YES)
---
> 		    (GTK_WINDOW (toplevel), 0 /* flags */ ,
> 		     GTK_MESSAGE_QUESTION,
> 		     GTK_BUTTONS_YES_NO,
> 		     _("File %s already exists. Overwrite?"), file);
> 		if (gtk_dialog_run (GTK_DIALOG (dialog)) !=
> 		    GTK_RESPONSE_YES)
210,217c224,230
< 			(GTK_WINDOW (toplevel),
< 			 0 /* flags */,
< 			 GTK_MESSAGE_ERROR,
< 			 GTK_BUTTONS_OK,
< 			 _("Unable to create the file:\n"
< 			   "\"%s\"\n"
< 			   "Please check your permissions of "
< 			   "the parent directory"), file);
---
> 		    (GTK_WINDOW (toplevel), 0 /* flags */ ,
> 		     GTK_MESSAGE_ERROR,
> 		     GTK_BUTTONS_OK,
> 		     _("Unable to create the file:\n"
> 		       "\"%s\"\n"
> 		       "Please check your permissions of "
> 		       "the parent directory"), file);
225c238
< save_to_file (FILE *fp, const gchar *file, gboolean gui_errors)
---
> save_to_file (FILE * fp, const gchar * file, gboolean gui_errors)
234c247
< 	if ( ! save_to_file_internal (fp, file, &error)) {
---
> 	if (!save_to_file_internal (fp, file, &error)) {
237,241c250,252
< 				(GTK_WINDOW (toplevel),
< 				 0 /* flags */,
< 				 GTK_MESSAGE_ERROR,
< 				 GTK_BUTTONS_OK,
< 				 "%s", error);
---
> 			    (GTK_WINDOW (toplevel), 0 /* flags */ ,
> 			     GTK_MESSAGE_ERROR,
> 			     GTK_BUTTONS_OK, "%s", error);
297,298c308
< 		if (fp == NULL ||
< 		    ! save_to_file (fp, file, FALSE)) {
---
> 		if (fp == NULL || !save_to_file (fp, file, FALSE)) {
308,309c318
< 		if (fp == NULL ||
< 		    ! save_to_file (fp, file, TRUE)) {
---
> 		if (fp == NULL || !save_to_file (fp, file, TRUE)) {
338,339c347
< 	if (WIFEXITED (status) &&
< 	    WEXITSTATUS (status) == 0) {
---
> 	if (WIFEXITED (status) && WEXITSTATUS (status) == 0) {
362c370
< 	
---
> 
378c386
< rotate_image (GdkPixbuf *image)
---
> rotate_image (GdkPixbuf * image)
387,393c395,402
< 	retval = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, height, width);
< 	affine[0] = 0.0;    /* = cos(90) */
< 	affine[2] = 1.0;    /* = sin(90) */
< 	affine[3] = 0.0;    /* = cos(90) */
< 	affine[1] = -1.0;   /* = -sin(90) */
< 	affine[4] = 0;      /* x translation */
< 	affine[5] = width;  /* y translation */
---
> 	retval =
> 	    gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, height, width);
> 	affine[0] = 0.0;	/* = cos(90) */
> 	affine[2] = 1.0;	/* = sin(90) */
> 	affine[3] = 0.0;	/* = cos(90) */
> 	affine[1] = -1.0;	/* = -sin(90) */
> 	affine[4] = 0;		/* x translation */
> 	affine[5] = width;	/* y translation */
402,404c411
< 			affine,
< 			ART_FILTER_NEAREST,
< 			NULL);
---
> 			affine, ART_FILTER_NEAREST, NULL);
412c419
< print_page (GnomePrintContext *context, const GnomePaper *paper)
---
> print_page (GnomePrintContext * context, const GnomePaper * paper)
423c430,431
< 	if (gdk_pixbuf_get_width (screenshot) > gdk_pixbuf_get_height (screenshot)) {
---
> 	if (gdk_pixbuf_get_width (screenshot) >
> 	    gdk_pixbuf_get_height (screenshot)) {
436,437c444,445
< 	if (((gdouble) pix_height/pix_width) >
< 	    ((gdouble)width/height)) {
---
> 	if (((gdouble) pix_height / pix_width) >
> 	    ((gdouble) width / height)) {
439c447
< 		width = height * (gdouble)pix_width/pix_height;
---
> 		width = height * (gdouble) pix_width / pix_height;
442c450
< 		height = width * (gdouble)pix_height/pix_width;
---
> 		height = width * (gdouble) pix_height / pix_width;
448c456,457
< 	gnome_print_translate (context, (real_width-width)/2.0, (real_height - height)/2.0);
---
> 	gnome_print_translate (context, (real_width - width) / 2.0,
> 			       (real_height - height) / 2.0);
452c461
<   
---
> 
477,478c486,491
< 	print_dialog = GNOME_PRINT_DIALOG (gnome_print_dialog_new (_("Print Screenshot"), GNOME_PRINT_DIALOG_COPIES));
< 	gnome_dialog_set_parent (GNOME_DIALOG (print_dialog), GTK_WINDOW (toplevel));
---
> 	print_dialog =
> 	    GNOME_PRINT_DIALOG (gnome_print_dialog_new
> 				(_("Print Screenshot"),
> 				 GNOME_PRINT_DIALOG_COPIES));
> 	gnome_dialog_set_parent (GNOME_DIALOG (print_dialog),
> 				 GTK_WINDOW (toplevel));
480c493
< 		result = gnome_dialog_run (GNOME_DIALOG (print_dialog)); 
---
> 		result = gnome_dialog_run (GNOME_DIALOG (print_dialog));
496c509,510
< 		gnome_print_dialog_get_copies (print_dialog, &copies, &collate);
---
> 		gnome_print_dialog_get_copies (print_dialog, &copies,
> 					       &collate);
498c512,514
< 		gnome_print_master_set_printer (gpm, gnome_print_dialog_get_printer (print_dialog));
---
> 		gnome_print_master_set_printer (gpm,
> 						gnome_print_dialog_get_printer
> 						(print_dialog));
503,504c519,522
< 		width = (unsigned int)(size_t)nl_langinfo (_NL_PAPER_WIDTH);
< 		height = (unsigned int)(size_t)nl_langinfo (_NL_PAPER_HEIGHT);
---
> 		width =
> 		    (unsigned int) (size_t) nl_langinfo (_NL_PAPER_WIDTH);
> 		height =
> 		    (unsigned int) (size_t) nl_langinfo (_NL_PAPER_HEIGHT);
506c524,525
< 		g_print ("%f %f\n", gnome_paper_convert_to_points (width, unit),
---
> 		g_print ("%f %f\n",
> 			 gnome_paper_convert_to_points (width, unit),
508,509c527,531
< 		paper = gnome_paper_with_size (gnome_paper_convert_to_points (width, unit),
< 					       gnome_paper_convert_to_points (height, unit));
---
> 		paper =
> 		    gnome_paper_with_size (gnome_paper_convert_to_points
> 					   (width, unit),
> 					   gnome_paper_convert_to_points
> 					   (height, unit));
511c533,534
< 		paper = gnome_paper_with_name (gnome_paper_name_default ());
---
> 		paper =
> 		    gnome_paper_with_name (gnome_paper_name_default ());
525,526c548,552
< 		gpmp = gnome_print_master_preview_new (gpm, _("Screenshot Print Preview"));
< 		g_signal_connect (G_OBJECT (gpmp), "destroy", 
---
> 		gpmp =
> 		    gnome_print_master_preview_new (gpm,
> 						    _
> 						    ("Screen shot Print Preview"));
> 		g_signal_connect (G_OBJECT (gpmp), "destroy",
528c554,555
< 		gtk_widget_set_sensitive (GTK_WIDGET (print_dialog), FALSE);
---
> 		gtk_widget_set_sensitive (GTK_WIDGET (print_dialog),
> 					  FALSE);
530c557,558
< 		gdk_window_set_cursor (GTK_WIDGET (print_dialog)->window, cursor);
---
> 		gdk_window_set_cursor (GTK_WIDGET (print_dialog)->window,
> 				       cursor);
535c563,564
< 		gtk_window_set_transient_for (GTK_WINDOW (gpmp), GTK_WINDOW (print_dialog));
---
> 		gtk_window_set_transient_for (GTK_WINDOW (gpmp),
> 					      GTK_WINDOW (print_dialog));
538c567,568
< 		gdk_window_set_cursor (GTK_WIDGET (print_dialog)->window, NULL);
---
> 		gdk_window_set_cursor (GTK_WIDGET (print_dialog)->window,
> 				       NULL);
544c574
< add_file_to_path (const gchar *path)
---
> add_file_to_path (const gchar * path)
553,554c583
< 	}
< 	else {
---
> 	} else {
559c588
< 	
---
> 
563,564c592
< 		if (stat (retval, &s) &&
< 		    errno == ENOENT)
---
> 		if (stat (retval, &s) && errno == ENOENT)
571,574c599,603
< 			retval = g_strdup_printf (_("%s%cScreenshot-%s-%d.png"), path,
< 						  G_DIR_SEPARATOR, class_name, i);
< 		}
< 		else {
---
> 			retval =
> 			    g_strdup_printf (_("%s%cScreenshot-%s-%d.png"),
> 					     path, G_DIR_SEPARATOR,
> 					     class_name, i);
> 		} else {
576,577c605,607
< 			retval = g_strdup_printf (_("%s%cScreenshot-%d.png"), path,
< 						  G_DIR_SEPARATOR, i);
---
> 			retval =
> 			    g_strdup_printf (_("%s%cScreenshot-%d.png"),
> 					     path, G_DIR_SEPARATOR, i);
579c609
< 		
---
> 
584a615,627
> static gboolean
> delay_callback (gpointer data)
> {
> 	if (timeout != 0) {
> 		gtk_timeout_remove (timeout);
> 		timeout = 0;
> 	}
> 
> 	take_shot ();
> 
> 	return FALSE;
> }
> 
586c629
< on_save_rbutton_toggled (GtkWidget *toggle, gpointer data)
---
> on_save_rbutton_toggled (GtkWidget * toggle, gpointer data)
588c631,632
< 	GtkWidget *save_fileentry = glade_xml_get_widget (xml, "save_fileentry");
---
> 	GtkWidget *save_fileentry =
> 	    glade_xml_get_widget (xml, "save_fileentry");
597,599c641,642
< on_preview_expose_event (GtkWidget      *drawing_area,
< 			 GdkEventExpose *event,
< 			 gpointer        data)
---
> on_preview_expose_event (GtkWidget * drawing_area,
> 			 GdkEventExpose * event, gpointer data)
608,609c651,656
< 			    + (event->area.y * gdk_pixbuf_get_rowstride (preview_image))
< 			    + (event->area.x * gdk_pixbuf_get_n_channels (preview_image)),
---
> 			    +
> 			    (event->area.y *
> 			     gdk_pixbuf_get_rowstride (preview_image))
> 			    +
> 			    (event->area.x *
> 			     gdk_pixbuf_get_n_channels (preview_image)),
614,616c661,662
< on_preview_configure_event (GtkWidget         *drawing_area,
< 			    GdkEventConfigure *event,
< 			    gpointer           data)
---
> on_preview_configure_event (GtkWidget * drawing_area,
> 			    GdkEventConfigure * event, gpointer data)
644,646c690,691
< 		(G_OBJECT (preview),
< 		 G_CALLBACK (on_preview_expose_event),
< 		 NULL);
---
> 	    (G_OBJECT (preview),
> 	     G_CALLBACK (on_preview_expose_event), NULL);
648c693
< 	gtk_widget_set_sensitive (toplevel, ! busy);
---
> 	gtk_widget_set_sensitive (toplevel, !busy);
652,654c697,698
< 		(G_OBJECT (preview),
< 		 G_CALLBACK (on_preview_expose_event),
< 		 NULL);
---
> 	    (G_OBJECT (preview),
> 	     G_CALLBACK (on_preview_expose_event), NULL);
694c738,739
< 		outfd = open (filename, O_CREAT|O_TRUNC|O_WRONLY, 0644);
---
> 		outfd =
> 		    open (filename, O_CREAT | O_TRUNC | O_WRONLY, 0644);
698,705c743,749
< 				(GTK_WINDOW (toplevel),
< 				 0 /* flags */,
< 				 GTK_MESSAGE_ERROR,
< 				 GTK_BUTTONS_OK,
< 				 _("Unable to create the file:\n"
< 				   "\"%s\"\n"
< 				   "Please check your permissions of "
< 				   "the parent directory"), filename);
---
> 			    (GTK_WINDOW (toplevel), 0 /* flags */ ,
> 			     GTK_MESSAGE_ERROR,
> 			     GTK_BUTTONS_OK,
> 			     _("Unable to create the file:\n"
> 			       "\"%s\"\n"
> 			       "Please check your permissions of "
> 			       "the parent directory"), filename);
718,723c762,766
< 					(GTK_WINDOW (toplevel),
< 					 0 /* flags */,
< 					 GTK_MESSAGE_ERROR,
< 					 GTK_BUTTONS_OK,
< 					 _("Not enough room to write file %s"),
< 					 filename);
---
> 				    (GTK_WINDOW (toplevel), 0 /* flags */ ,
> 				     GTK_MESSAGE_ERROR,
> 				     GTK_BUTTONS_OK,
> 				     _("Not enough room to write file %s"),
> 				     filename);
739,740c782
< on_ok_button_clicked (GtkWidget *widget,
< 		      gpointer   data)
---
> on_ok_button_clicked (GtkWidget * widget, gpointer data)
778a821,828
> 	button = glade_xml_get_widget (xml, "another_rbutton");
> 	if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (button))) {
> 		gtk_widget_hide (toplevel);
> 		setup_busy (FALSE);
> 		prompt_delay ();
> 		return;
> 	}
> 
780c830
< 	if ( ! gimme_file (file)) {
---
> 	if (!gimme_file (file)) {
793c843
< on_cancel_button_clicked (GtkWidget *widget, gpointer data)
---
> on_cancel_button_clicked (GtkWidget * widget, gpointer data)
799,800c849
< on_toplevel_key_press_event (GtkWidget *widget,
< 			     GdkEventKey *key)
---
> on_toplevel_key_press_event (GtkWidget * widget, GdkEventKey * key)
808a858,897
> void
> on_window_rbutton_toggled (GtkWidget * toggle, gpointer data)
> {
> 	window = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle));
> }
> 
> void
> on_screen_rbutton_toggled (GtkWidget * toggle, gpointer data)
> {
> 	window =
> 	    !gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle));
> }
> 
> void
> on_delay_spin_value_changed (GtkWidget * spin, gpointer data)
> {
> 	guint value;
> 
> 	/* Change delay */
> 	value = (guint) gtk_spin_button_get_value (GTK_SPIN_BUTTON (spin));
> }
> 
> void
> on_delay_response (GtkWidget * dialog, gint response_id, gpointer data)
> {
> 	switch (response_id) {
> 	case GTK_RESPONSE_YES:
> 		gtk_widget_destroy (dialog);
> 		timeout =
> 		    gtk_timeout_add ((delay * 1000),
> 				     (GtkFunction) delay_callback, NULL);
> 		gtk_widget_show_now (toplevel);
> 		break;
> 	case GTK_RESPONSE_NO:
> 		gtk_widget_destroy (dialog);
> 		gtk_widget_show_now (toplevel);
> 		break;
> 	}
> }
> 
811c900
< find_toplevel_window (int depth, Window xid, gboolean *keep_going)
---
> find_toplevel_window (int depth, Window xid, gboolean * keep_going)
833,835c922,924
< 				(guchar **) &prop) == Success
< 	    && prop != NULL && actual_format == 32 && prop[0] == NormalState)
< 	{
---
> 				(guchar **) & prop) == Success
> 	    && prop != NULL && actual_format == 32
> 	    && prop[0] == NormalState) {
850,851c939
< 				&parent, &children, &nchildren) != 0)
< 		{
---
> 				&parent, &children, &nchildren) != 0) {
864c952
< 			if (! *keep_going) {
---
> 			if (!*keep_going) {
887c975
< 	
---
> 
892,896c980
< 		       &unused,
< 		       &unused,
< 		       &unused,
< 		       &unused,
< 		       &mask);
---
> 		       &unused, &unused, &unused, &unused, &mask);
899c983
<                 window = gdk_get_default_root_window ();
---
> 		window = gdk_get_default_root_window ();
902c986
<                 window = gdk_window_foreign_new (child);
---
> 		window = gdk_window_foreign_new (child);
909c993,996
< 		if (toplevel && (XGetClassHint (GDK_DISPLAY (), toplevel, &class_hint) != 0)) {
---
> 		if (toplevel
> 		    &&
> 		    (XGetClassHint (GDK_DISPLAY (), toplevel, &class_hint)
> 		     != 0)) {
920c1007
< 	
---
> 
922c1009
< 		x = - x_orig;
---
> 		x = -x_orig;
927c1014
< 		y = - y_orig;
---
> 		y = -y_orig;
936c1023
< 			
---
> 
953,955c1040,1078
< 	screenshot = gdk_pixbuf_get_from_drawable (NULL, gdk_get_default_root_window (),
< 						   NULL, 0, 0, 0, 0,
< 						   width, height);
---
> 	screenshot =
> 	    gdk_pixbuf_get_from_drawable (NULL,
> 					  gdk_get_default_root_window (),
> 					  NULL, 0, 0, 0, 0, width, height);
> }
> 
> static void
> take_shot (void)
> {
> 	if (window) {
> 		take_window_shot ();
> 	} else {
> 		take_screen_shot ();
> 	}
> 
> 	if (screenshot == NULL) {
> 		GtkWidget *dialog;
> 		dialog = gtk_message_dialog_new (NULL /* parent */ ,
> 						 0 /* flags */ ,
> 						 GTK_MESSAGE_ERROR,
> 						 GTK_BUTTONS_OK,
> 						 _
> 						 ("Unable to take a screenshot of "
> 						  "the current desktop."));
> 		gtk_dialog_run (GTK_DIALOG (dialog));
> 		exit (1);
> 	} else {
> 		gint width, height;
> 
> 		width = gdk_pixbuf_get_width (screenshot);
> 		height = gdk_pixbuf_get_height (screenshot);
> 		width /= 5;
> 		height /= 5;
> 
> 		/* This reload therefore repaint the widget */
> 		preview_image =
> 		    gdk_pixbuf_scale_simple (screenshot, width, height,
> 					     GDK_INTERP_BILINEAR);
> 	}
959,964c1082,1085
< drag_data_get (GtkWidget          *widget,
< 	       GdkDragContext     *context,
< 	       GtkSelectionData   *selection_data,
< 	       guint               info,
< 	       guint               time,
< 	       gpointer            data)
---
> drag_data_get (GtkWidget * widget,
> 	       GdkDragContext * context,
> 	       GtkSelectionData * selection_data,
> 	       guint info, guint time, gpointer data)
968,969c1089,1090
< 	if ( ! ensure_temporary ()) {
< 		/*FIXME: cancel the drag*/
---
> 	if (!ensure_temporary ()) {
> 		/*FIXME: cancel the drag */
976c1097
< 				8, string, strlen (string)+1);
---
> 				8, string, strlen (string) + 1);
984c1105
< 	
---
> 
986,987c1107,1108
< 	signal (sig, SIG_DFL); 
< 	kill (getpid (), sig); 
---
> 	signal (sig, SIG_DFL);
> 	kill (getpid (), sig);
991c1112
< drag_begin (GtkWidget *widget, GdkDragContext *context)
---
> drag_begin (GtkWidget * widget, GdkDragContext * context)
997,999c1118,1119
< 		(preview_image, &pixmap, &mask,
< 		 128);
< 	
---
> 	    (preview_image, &pixmap, &mask, 128);
> 
1001,1002c1121,1122
< 		(context, gdk_rgb_get_colormap (), pixmap, mask, 0, 0);
< 	
---
> 	    (context, gdk_rgb_get_colormap (), pixmap, mask, 0, 0);
> 
1005a1126,1231
> static void
> prompt_delay (void)
> {
> 	GtkWidget *vbox, *frame, *frame_label, *picture_vbox;
> 	GtkWidget *window_rbutton, *screen_rbutton;
> 	GtkWidget *desc, *label1, *label2;
> 	GtkWidget *table, *delay_spin;
> 	GSList *picture_group = NULL;
> 
> 	delay_dialog =
> 	    gtk_dialog_new_with_buttons (_("Take a screen shot"), NULL,
> 					 GTK_DIALOG_MODAL, GTK_STOCK_NO,
> 					 GTK_RESPONSE_NO, GTK_STOCK_YES,
> 					 GTK_RESPONSE_YES, NULL);
> 	gtk_window_set_resizable (GTK_WINDOW (delay_dialog), FALSE);
> 	gtk_dialog_set_default_response (GTK_DIALOG (delay_dialog),
> 					 GTK_RESPONSE_NO);
> 
> 	vbox = gtk_vbox_new (FALSE, 8);
> 	gtk_box_pack_start (GTK_BOX (GTK_DIALOG (delay_dialog)->vbox),
> 			    vbox, TRUE, TRUE, 0);
> 	gtk_container_set_border_width (GTK_CONTAINER (vbox), 8);
> 
> 	desc =
> 	    gtk_label_new (_
> 			   ("<b>Choose the screen shot type and the delay.</b>"));
> 	gtk_label_set_use_markup (GTK_LABEL (desc), TRUE);
> 	gtk_box_pack_start (GTK_BOX (vbox), desc, FALSE, FALSE, 0);
> 
> 	frame = gtk_frame_new (NULL);
> 	gtk_box_pack_start (GTK_BOX (vbox), frame, TRUE, TRUE, 0);
> 
> 	picture_vbox = gtk_vbox_new (FALSE, 8);
> 	gtk_container_add (GTK_CONTAINER (frame), picture_vbox);
> 	gtk_container_set_border_width (GTK_CONTAINER (picture_vbox), 4);
> 
> 	window_rbutton =
> 	    gtk_radio_button_new_with_mnemonic (NULL, _("Single _window"));
> 	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (window_rbutton),
> 				      window);
> 	gtk_box_pack_start (GTK_BOX (picture_vbox), window_rbutton, FALSE,
> 			    FALSE, 0);
> 	gtk_radio_button_set_group (GTK_RADIO_BUTTON (window_rbutton),
> 				    picture_group);
> 	picture_group =
> 	    gtk_radio_button_get_group (GTK_RADIO_BUTTON (window_rbutton));
> 
> 	screen_rbutton =
> 	    gtk_radio_button_new_with_mnemonic (NULL, _("Whole _screen"));
> 	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (screen_rbutton),
> 				      !window);
> 	gtk_box_pack_start (GTK_BOX (picture_vbox), screen_rbutton, FALSE,
> 			    FALSE, 0);
> 	gtk_radio_button_set_group (GTK_RADIO_BUTTON (screen_rbutton),
> 				    picture_group);
> 	picture_group =
> 	    gtk_radio_button_get_group (GTK_RADIO_BUTTON (screen_rbutton));
> 
> 	frame_label = gtk_label_new (_("Picture"));
> 	gtk_frame_set_label_widget (GTK_FRAME (frame), frame_label);
> 	gtk_label_set_justify (GTK_LABEL (frame_label), GTK_JUSTIFY_LEFT);
> 
> 	table = gtk_table_new (1, 3, FALSE);
> 	gtk_box_pack_start (GTK_BOX (vbox), table, TRUE, TRUE, 0);
> 	gtk_table_set_row_spacings (GTK_TABLE (table), 8);
> 	gtk_table_set_col_spacings (GTK_TABLE (table), 8);
> 
> 	label1 = gtk_label_new_with_mnemonic (_("_After:"));
> 	gtk_table_attach (GTK_TABLE (table), label1, 0, 1, 0, 1,
> 			  (GtkAttachOptions) (GTK_FILL),
> 			  (GtkAttachOptions) (0), 0, 0);
> 	gtk_label_set_justify (GTK_LABEL (label1), GTK_JUSTIFY_LEFT);
> 	gtk_misc_set_alignment (GTK_MISC (label1), 0, 0.5);
> 	gtk_misc_set_padding (GTK_MISC (label1), 0, 4);
> 
> 	delay_spin =
> 	    gtk_spin_button_new (GTK_ADJUSTMENT
> 				 (gtk_adjustment_new
> 				  (delay, 0, 100, 1, 5, 0)), 0, 0);
> 	gtk_table_attach (GTK_TABLE (table), delay_spin, 1, 2, 0, 1,
> 			  (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
> 			  (GtkAttachOptions) (0), 0, 0);
> 	gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (delay_spin), TRUE);
> 
> 	label2 = gtk_label_new (_("second(s)"));
> 	gtk_table_attach (GTK_TABLE (table), label2, 2, 3, 0, 1,
> 			  (GtkAttachOptions) (GTK_FILL),
> 			  (GtkAttachOptions) (0), 0, 0);
> 	gtk_label_set_justify (GTK_LABEL (label2), GTK_JUSTIFY_LEFT);
> 	gtk_misc_set_alignment (GTK_MISC (label2), 0, 0.5);
> 
> 	gtk_label_set_mnemonic_widget (GTK_LABEL (label1), delay_spin);
> 
> 	g_signal_connect (G_OBJECT (delay_dialog), "response",
> 			  G_CALLBACK (on_delay_response), NULL);
> 	g_signal_connect (G_OBJECT (window_rbutton), "toggled",
> 			  G_CALLBACK (on_window_rbutton_toggled), NULL);
> 	g_signal_connect (G_OBJECT (screen_rbutton), "toggled",
> 			  G_CALLBACK (on_screen_rbutton_toggled), NULL);
> 	g_signal_connect (G_OBJECT (delay_spin), "value_changed",
> 			  G_CALLBACK (on_delay_spin_value_changed), NULL);
> 
> 	gtk_widget_show_all (GTK_DIALOG (delay_dialog)->vbox);
> 	gtk_dialog_run (GTK_DIALOG (delay_dialog));
> }
> 
1016,1018c1242
< 	gboolean window = FALSE;
< 	gint width, height; 
< 	guint delay = 0;
---
> 	gint width, height;
1021,1022c1245,1252
< 		{"window", '\0', POPT_ARG_NONE, &window, 0, N_("Grab a window instead of the entire screen"), NULL},
< 		{"delay", '\0', POPT_ARG_INT, &delay, 0, N_("Take screenshot after specified delay [in seconds]"), NULL},
---
> 		{"window", '\0', POPT_ARG_NONE, &window, 0,
> 		 N_("Grab a window instead of the entire screen"), NULL},
> 		{"delay", '\0', POPT_ARG_INT, &delay, 0,
> 		 N_
> 		 ("Take a screen shot after specified delay [in seconds]"),
> 		 NULL},
> 		{"options", '\0', POPT_ARG_NONE, &options, 0,
> 		 N_("Specify the screen shot type and delay"), NULL},
1035,1037c1265,1266
< 			    GNOME_PROGRAM_STANDARD_PROPERTIES,
< 			    NULL);
< 	glade_gnome_init();
---
> 			    GNOME_PROGRAM_STANDARD_PROPERTIES, NULL);
> 	glade_gnome_init ();
1040,1044c1269,1274
< 	
< 	if (delay > 0) {
< 		sleep (delay);	
< 	}
< 	
---
> 
> 	if (delay > 0)
> 		timeout =
> 		    gtk_timeout_add ((delay * 1000),
> 				     (GtkFunction) delay_callback, NULL);
> 
1050,1051c1280,1284
< 	if (g_file_test ("gnome-panel-screenshot.glade2", G_FILE_TEST_EXISTS)) {
< 		xml = glade_xml_new ("gnome-panel-screenshot.glade2", NULL, NULL);
---
> 	if (g_file_test
> 	    ("gnome-panel-screenshot.glade2", G_FILE_TEST_EXISTS)) {
> 		xml =
> 		    glade_xml_new ("gnome-panel-screenshot.glade2", NULL,
> 				   NULL);
1054,1055c1287,1290
< 		xml = glade_xml_new (GLADEDIR "/gnome-panel-screenshot.glade2",
< 				     NULL, NULL);
---
> 		xml =
> 		    glade_xml_new (GLADEDIR
> 				   "/gnome-panel-screenshot.glade2", NULL,
> 				   NULL);
1059,1065c1294,1300
< 		dialog = gtk_message_dialog_new
< 			(NULL /* parent */,
< 			 0 /* flags */,
< 			 GTK_MESSAGE_ERROR,
< 			 GTK_BUTTONS_OK,
< 			 _("Glade file for the screenshot program is missing.\n"
< 			   "Please check your installation of gnome-panel"));
---
> 		dialog = gtk_message_dialog_new (NULL /* parent */ ,
> 						 0 /* flags */ ,
> 						 GTK_MESSAGE_ERROR,
> 						 GTK_BUTTONS_OK,
> 						 _
> 						 ("Glade file for the screenshot program is missing.\n"
> 						  "Please check your installation of gnome-panel"));
1073c1308,1309
< 		GtkWidget *button = glade_xml_get_widget (xml, "print_rbutton");
---
> 		GtkWidget *button =
> 		    glade_xml_get_widget (xml, "print_rbutton");
1081,1087c1317,1323
< 		dialog = gtk_message_dialog_new
< 			(NULL /* parent */,
< 			 0 /* flags */,
< 			 GTK_MESSAGE_ERROR,
< 			 GTK_BUTTONS_OK,
< 			_("Unable to take a screenshot of "
< 			   "the current desktop."));
---
> 		dialog = gtk_message_dialog_new (NULL /* parent */ ,
> 						 0 /* flags */ ,
> 						 GTK_MESSAGE_ERROR,
> 						 GTK_BUTTONS_OK,
> 						 _
> 						 ("Unable to take a screenshot of "
> 						  "the current desktop."));
1106c1342
< 			      gdk_pixbuf_get_width (screenshot)/
---
> 			      gdk_pixbuf_get_width (screenshot) /
1110c1346,1347
< 		gtk_frame_set_shadow_type (GTK_FRAME (frame), GTK_SHADOW_NONE);
---
> 		gtk_frame_set_shadow_type (GTK_FRAME (frame),
> 					   GTK_SHADOW_NONE);
1117c1354,1356
< 	if (gconf_client_get_bool (gconf_client, "/apps/nautilus/preferences/desktop_is_home_dir", NULL))
---
> 	if (gconf_client_get_bool
> 	    (gconf_client,
> 	     "/apps/nautilus/preferences/desktop_is_home_dir", NULL))
1123c1362
< 	
---
> 
1128,1129c1367
< 	if (! stat (web_dir, &s) &&
< 	    S_ISDIR (s.st_mode)) {
---
> 	if (!stat (web_dir, &s) && S_ISDIR (s.st_mode)) {
1136a1375,1376
> 	g_signal_connect (G_OBJECT (toplevel), "destroy",
> 			  G_CALLBACK (gtk_main_quit), NULL);
1141,1144c1381,1382
< 	gtk_drag_source_set (preview,
< 			     GDK_BUTTON1_MASK|GDK_BUTTON3_MASK,
< 			     drag_types, 2,
< 			     GDK_ACTION_COPY);
---
> 	gtk_drag_source_set (preview, GDK_BUTTON1_MASK | GDK_BUTTON3_MASK,
> 			     drag_types, 2, GDK_ACTION_COPY);
1148,1150d1385
< 	g_signal_connect (G_OBJECT (save_entry), "activate",
< 			  G_CALLBACK (on_ok_button_clicked),
< 			  NULL);
1152c1387,1390
< 	gtk_widget_show_now (toplevel);
---
> 	if (options)
> 		prompt_delay ();
> 	else
> 		gtk_widget_show_now (toplevel);
Index: gnome-panel/gnome-panel-screenshot.glade2
===================================================================
RCS file: /cvs/gnome/gnome-panel/gnome-panel/gnome-panel-screenshot.glade2,v
retrieving revision 1.1
diff -r1.1 gnome-panel-screenshot.glade2
2c2
< <!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd" >
---
> <!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
5c5,294
<   <requires lib="gnome" />
---
> <requires lib="gnome"/>
> 
> <widget class="GtkWindow" id="toplevel">
>   <property name="title" translatable="yes">Screen shot</property>
>   <property name="type">GTK_WINDOW_TOPLEVEL</property>
>   <property name="window_position">GTK_WIN_POS_NONE</property>
>   <property name="modal">False</property>
>   <property name="resizable">True</property>
>   <property name="destroy_with_parent">False</property>
>   <signal name="delete_event" handler="gtk_main_quit"/>
>   <signal name="key_press_event" handler="on_toplevel_key_press_event"/>
> 
>   <child>
>     <widget class="GtkVBox" id="vbox1">
>       <property name="border_width">8</property>
>       <property name="visible">True</property>
>       <property name="homogeneous">False</property>
>       <property name="spacing">8</property>
> 
>       <child>
> 	<widget class="GtkFrame" id="frame3">
> 	  <property name="visible">True</property>
> 	  <property name="label_xalign">0</property>
> 	  <property name="label_yalign">0.5</property>
> 	  <property name="shadow_type">GTK_SHADOW_ETCHED_IN</property>
> 
> 	  <child>
> 	    <widget class="GtkAspectFrame" id="aspect_frame">
> 	      <property name="border_width">8</property>
> 	      <property name="visible">True</property>
> 	      <property name="label_xalign">0</property>
> 	      <property name="label_yalign">0.5</property>
> 	      <property name="shadow_type">GTK_SHADOW_IN</property>
> 	      <property name="xalign">0.5</property>
> 	      <property name="yalign">0.5</property>
> 	      <property name="ratio">1</property>
> 	      <property name="obey_child">True</property>
> 
> 	      <child>
> 		<widget class="GtkDrawingArea" id="preview">
> 		  <property name="visible">True</property>
> 		  <signal name="expose_event" handler="on_preview_expose_event"/>
> 		  <signal name="configure_event" handler="on_preview_configure_event"/>
> 		</widget>
> 	      </child>
> 	    </widget>
> 	  </child>
> 
> 	  <child>
> 	    <widget class="GtkLabel" id="label1">
> 	      <property name="visible">True</property>
> 	      <property name="label" translatable="yes">Preview</property>
> 	      <property name="use_underline">False</property>
> 	      <property name="use_markup">False</property>
> 	      <property name="justify">GTK_JUSTIFY_LEFT</property>
> 	      <property name="wrap">False</property>
> 	      <property name="selectable">False</property>
> 	      <property name="xalign">0.5</property>
> 	      <property name="yalign">0.5</property>
> 	      <property name="xpad">0</property>
> 	      <property name="ypad">0</property>
> 	    </widget>
> 	    <packing>
> 	      <property name="type">label_item</property>
> 	    </packing>
> 	  </child>
> 	</widget>
> 	<packing>
> 	  <property name="padding">0</property>
> 	  <property name="expand">True</property>
> 	  <property name="fill">True</property>
> 	</packing>
>       </child>
> 
>       <child>
> 	<widget class="GtkFrame" id="options_frame">
> 	  <property name="visible">True</property>
> 	  <property name="label_xalign">0</property>
> 	  <property name="label_yalign">0.5</property>
> 	  <property name="shadow_type">GTK_SHADOW_ETCHED_IN</property>
> 
> 	  <child>
> 	    <widget class="GtkVBox" id="vbox2">
> 	      <property name="border_width">8</property>
> 	      <property name="visible">True</property>
> 	      <property name="homogeneous">False</property>
> 	      <property name="spacing">4</property>
> 
> 	      <child>
> 		<widget class="GtkHBox" id="hbox1">
> 		  <property name="visible">True</property>
> 		  <property name="homogeneous">False</property>
> 		  <property name="spacing">4</property>
> 
> 		  <child>
> 		    <widget class="GtkRadioButton" id="save_rbutton">
> 		      <property name="visible">True</property>
> 		      <property name="can_focus">True</property>
> 		      <property name="label" translatable="yes">_Save screen shot to file:</property>
> 		      <property name="use_underline">True</property>
> 		      <property name="relief">GTK_RELIEF_NORMAL</property>
> 		      <property name="active">False</property>
> 		      <property name="inconsistent">False</property>
> 		      <property name="draw_indicator">True</property>
> 		      <signal name="toggled" handler="on_save_rbutton_toggled"/>
> 		    </widget>
> 		    <packing>
> 		      <property name="padding">0</property>
> 		      <property name="expand">False</property>
> 		      <property name="fill">False</property>
> 		    </packing>
> 		  </child>
> 
> 		  <child>
> 		    <widget class="GnomeFileEntry" id="save_fileentry">
> 		      <property name="visible">True</property>
> 		      <property name="max_saved">10</property>
> 		      <property name="directory_entry">True</property>
> 		      <property name="modal">False</property>
> 
> 		      <child internal-child="entry">
> 			<widget class="GtkEntry" id="save_entry">
> 			  <property name="visible">True</property>
> 			  <property name="can_focus">True</property>
> 			  <property name="editable">True</property>
> 			  <property name="visibility">True</property>
> 			  <property name="max_length">0</property>
> 			  <property name="text" translatable="yes"></property>
> 			  <property name="has_frame">True</property>
> 			  <property name="invisible_char" translatable="yes">*</property>
> 			  <property name="activates_default">False</property>
> 			</widget>
> 		      </child>
> 		    </widget>
> 		    <packing>
> 		      <property name="padding">0</property>
> 		      <property name="expand">True</property>
> 		      <property name="fill">True</property>
> 		    </packing>
> 		  </child>
> 		</widget>
> 		<packing>
> 		  <property name="padding">0</property>
> 		  <property name="expand">False</property>
> 		  <property name="fill">False</property>
> 		</packing>
> 	      </child>
> 
> 	      <child>
> 		<widget class="GtkRadioButton" id="desktop_rbutton">
> 		  <property name="visible">True</property>
> 		  <property name="can_focus">True</property>
> 		  <property name="label" translatable="yes">Save screen shot to _desktop</property>
> 		  <property name="use_underline">True</property>
> 		  <property name="relief">GTK_RELIEF_NORMAL</property>
> 		  <property name="active">False</property>
> 		  <property name="inconsistent">False</property>
> 		  <property name="draw_indicator">True</property>
> 		  <property name="group">save_rbutton</property>
> 		</widget>
> 		<packing>
> 		  <property name="padding">0</property>
> 		  <property name="expand">False</property>
> 		  <property name="fill">False</property>
> 		</packing>
> 	      </child>
> 
> 	      <child>
> 		<widget class="GtkRadioButton" id="web_rbutton">
> 		  <property name="can_focus">True</property>
> 		  <property name="label" translatable="yes">Save screen shot to _web page (save in ~/public__html)</property>
> 		  <property name="use_underline">True</property>
> 		  <property name="relief">GTK_RELIEF_NORMAL</property>
> 		  <property name="active">False</property>
> 		  <property name="inconsistent">False</property>
> 		  <property name="draw_indicator">True</property>
> 		  <property name="group">save_rbutton</property>
> 		</widget>
> 		<packing>
> 		  <property name="padding">0</property>
> 		  <property name="expand">False</property>
> 		  <property name="fill">False</property>
> 		</packing>
> 	      </child>
> 
> 	      <child>
> 		<widget class="GtkRadioButton" id="print_rbutton">
> 		  <property name="visible">True</property>
> 		  <property name="can_focus">True</property>
> 		  <property name="label" translatable="yes">_Print screen shot...</property>
> 		  <property name="use_underline">True</property>
> 		  <property name="relief">GTK_RELIEF_NORMAL</property>
> 		  <property name="active">False</property>
> 		  <property name="inconsistent">False</property>
> 		  <property name="draw_indicator">True</property>
> 		  <property name="group">save_rbutton</property>
> 		</widget>
> 		<packing>
> 		  <property name="padding">0</property>
> 		  <property name="expand">False</property>
> 		  <property name="fill">False</property>
> 		</packing>
> 	      </child>
> 
> 	      <child>
> 		<widget class="GtkRadioButton" id="another_rbutton">
> 		  <property name="visible">True</property>
> 		  <property name="can_focus">True</property>
> 		  <property name="label" translatable="yes">_Take another screen shot</property>
> 		  <property name="use_underline">True</property>
> 		  <property name="relief">GTK_RELIEF_NORMAL</property>
> 		  <property name="active">False</property>
> 		  <property name="inconsistent">False</property>
> 		  <property name="draw_indicator">True</property>
> 		  <property name="group">save_rbutton</property>
> 		</widget>
> 		<packing>
> 		  <property name="padding">0</property>
> 		  <property name="expand">False</property>
> 		  <property name="fill">False</property>
> 		</packing>
> 	      </child>
> 	    </widget>
> 	  </child>
> 
> 	  <child>
> 	    <widget class="GtkLabel" id="label2">
> 	      <property name="visible">True</property>
> 	      <property name="label" translatable="yes">Options</property>
> 	      <property name="use_underline">False</property>
> 	      <property name="use_markup">False</property>
> 	      <property name="justify">GTK_JUSTIFY_LEFT</property>
> 	      <property name="wrap">False</property>
> 	      <property name="selectable">False</property>
> 	      <property name="xalign">0.5</property>
> 	      <property name="yalign">0.5</property>
> 	      <property name="xpad">0</property>
> 	      <property name="ypad">0</property>
> 	    </widget>
> 	    <packing>
> 	      <property name="type">label_item</property>
> 	    </packing>
> 	  </child>
> 	</widget>
> 	<packing>
> 	  <property name="padding">0</property>
> 	  <property name="expand">False</property>
> 	  <property name="fill">False</property>
> 	</packing>
>       </child>
> 
>       <child>
> 	<widget class="GtkHButtonBox" id="hbuttonbox1">
> 	  <property name="visible">True</property>
> 	  <property name="layout_style">GTK_BUTTONBOX_END</property>
> 	  <property name="spacing">25</property>
> 
> 	  <child>
> 	    <widget class="GtkButton" id="cancel_button">
> 	      <property name="visible">True</property>
> 	      <property name="can_default">True</property>
> 	      <property name="can_focus">True</property>
> 	      <property name="label">gtk-cancel</property>
> 	      <property name="use_stock">True</property>
> 	      <property name="relief">GTK_RELIEF_NORMAL</property>
> 	      <signal name="clicked" handler="on_cancel_button_clicked"/>
> 	    </widget>
> 	  </child>
> 
> 	  <child>
> 	    <widget class="GtkButton" id="ok_button">
> 	      <property name="visible">True</property>
> 	      <property name="can_default">True</property>
> 	      <property name="can_focus">True</property>
> 	      <property name="label">gtk-ok</property>
> 	      <property name="use_stock">True</property>
> 	      <property name="relief">GTK_RELIEF_NORMAL</property>
> 	      <signal name="clicked" handler="on_ok_button_clicked"/>
> 	    </widget>
> 	  </child>
> 	</widget>
> 	<packing>
> 	  <property name="padding">0</property>
> 	  <property name="expand">False</property>
> 	  <property name="fill">False</property>
> 	</packing>
>       </child>
>     </widget>
>   </child>
> </widget>
7,233d295
<   <widget class="GtkWindow" id="toplevel">
<     <property name="visible">no</property>
<     <property name="title" translatable="yes">Screenshot</property>
<     <property name="type">GTK_WINDOW_TOPLEVEL</property>
<     <property name="modal">no</property>
<     <property name="allow_shrink">no</property>
<     <property name="allow_grow">yes</property>
<     <property name="window-position">GTK_WIN_POS_NONE</property>
< 
<     <signal name="delete_event" handler="gtk_main_quit" />
<     <signal name="key_press_event" handler="on_toplevel_key_press_event" />
< 
<     <child>
<       <widget class="GtkVBox" id="vbox1">
<         <property name="border_width">8</property>
<         <property name="homogeneous">no</property>
<         <property name="spacing">8</property>
<         <property name="visible">yes</property>
< 
<         <child>
<           <widget class="GtkFrame" id="frame3">
<             <property name="label" translatable="yes">Preview</property>
<             <property name="label_xalign">0</property>
<             <property name="shadow">GTK_SHADOW_ETCHED_IN</property>
<             <property name="visible">yes</property>
< 
<             <child>
<               <widget class="GtkAspectFrame" id="aspect_frame">
<                 <property name="border_width">8</property>
<                 <property name="label_xalign">0</property>
<                 <property name="shadow_type">GTK_SHADOW_IN</property>
<                 <property name="xalign">0.5</property>
<                 <property name="yalign">0.5</property>
<                 <property name="ratio">1</property>
<                 <property name="obey_child">yes</property>
<                 <property name="visible">yes</property>
< 
<                 <child>
<                   <widget class="GtkDrawingArea" id="preview">
<                     <property name="visible">yes</property>
< 
<                     <signal name="expose_event" handler="on_preview_expose_event" />
<                     <signal name="configure_event" handler="on_preview_configure_event" />
<                   </widget>
<                 </child>
<               </widget>
<             </child>
<           </widget>
<           <packing>
<             <property name="padding">0</property>
<             <property name="expand">yes</property>
<             <property name="fill">yes</property>
<           </packing>
<         </child>
< 
<         <child>
<           <widget class="GtkFrame" id="options_frame">
<             <property name="label" translatable="yes">Options</property>
<             <property name="label_xalign">0</property>
<             <property name="shadow">GTK_SHADOW_ETCHED_IN</property>
<             <property name="visible">yes</property>
< 
<             <child>
<               <widget class="GtkVBox" id="vbox2">
<                 <property name="border_width">8</property>
<                 <property name="homogeneous">no</property>
<                 <property name="spacing">4</property>
<                 <property name="visible">yes</property>
< 
<                 <child>
<                   <widget class="GtkHBox" id="hbox1">
<                     <property name="homogeneous">no</property>
<                     <property name="spacing">4</property>
<                     <property name="visible">yes</property>
< 
<                     <child>
<                       <widget class="GtkRadioButton" id="save_rbutton">
<                         <property name="can_focus">yes</property>
<                         <property name="label" translatable="yes">_Save screenshot to file:</property>
<                         <property name="active">no</property>
<                         <property name="draw_indicator">yes</property>
<                         <property name="visible">yes</property>
<                         <property name="use_underline">yes</property>
< 
<                         <signal name="toggled" handler="on_save_rbutton_toggled" />
<                       </widget>
<                       <packing>
<                         <property name="padding">0</property>
<                         <property name="expand">no</property>
<                         <property name="fill">no</property>
<                       </packing>
<                     </child>
< 
<                     <child>
<                       <widget class="GnomeFileEntry" id="save_fileentry">
<                         <property name="modal">no</property>
<                         <property name="directory_entry">yes</property>
<                         <property name="visible">yes</property>
< 
<                         <child internal-child="entry">
<                           <widget class="GtkEntry" id="save_entry">
<                             <property name="can_focus">yes</property>
<                             <property name="editable">yes</property>
<                             <property name="text" translatable="yes"></property>
<                             <property name="max-length">0</property>
<                             <property name="visibility">yes</property>
<                             <property name="visible">yes</property>
<                           </widget>
<                         </child>
<                       </widget>
<                       <packing>
<                         <property name="padding">0</property>
<                         <property name="expand">yes</property>
<                         <property name="fill">yes</property>
<                       </packing>
<                     </child>
<                   </widget>
<                   <packing>
<                     <property name="padding">0</property>
<                     <property name="expand">no</property>
<                     <property name="fill">no</property>
<                   </packing>
<                 </child>
< 
<                 <child>
<                   <widget class="GtkRadioButton" id="desktop_rbutton">
<                     <property name="can_focus">yes</property>
<                     <property name="label" translatable="yes">Save screenshot to _desktop</property>
<                     <property name="active">no</property>
<                     <property name="draw_indicator">yes</property>
<                     <property name="visible">yes</property>
<                     <property name="group">save_rbutton</property>
<                     <property name="use_underline">yes</property>
<                   </widget>
<                   <packing>
<                     <property name="padding">0</property>
<                     <property name="expand">no</property>
<                     <property name="fill">no</property>
<                   </packing>
<                 </child>
< 
<                 <child>
<                   <widget class="GtkRadioButton" id="web_rbutton">
<                     <property name="visible">no</property>
<                     <property name="can_focus">yes</property>
<                     <property name="label" translatable="yes">Save screenshot to _web page (save in ~/public__html)</property>
<                     <property name="active">no</property>
<                     <property name="draw_indicator">yes</property>
<                     <property name="group">save_rbutton</property>
<                     <property name="use_underline">yes</property>
<                   </widget>
<                   <packing>
<                     <property name="padding">0</property>
<                     <property name="expand">no</property>
<                     <property name="fill">no</property>
<                   </packing>
<                 </child>
< 
<                 <child>
<                   <widget class="GtkRadioButton" id="print_rbutton">
<                     <property name="can_focus">yes</property>
<                     <property name="label" translatable="yes">_Print screenshot...</property>
<                     <property name="active">no</property>
<                     <property name="draw_indicator">yes</property>
<                     <property name="visible">yes</property>
<                     <property name="group">save_rbutton</property>
<                     <property name="use_underline">yes</property>
<                   </widget>
<                   <packing>
<                     <property name="padding">0</property>
<                     <property name="expand">no</property>
<                     <property name="fill">no</property>
<                   </packing>
<                 </child>
<               </widget>
<             </child>
<           </widget>
<           <packing>
<             <property name="padding">0</property>
<             <property name="expand">no</property>
<             <property name="fill">no</property>
<           </packing>
<         </child>
< 
<         <child>
<           <widget class="GtkHButtonBox" id="hbuttonbox1">
<             <property name="layout_style">GTK_BUTTONBOX_END</property>
<             <property name="spacing">25</property>
<             <property name="visible">yes</property>
< 
<             <child>
<               <widget class="GtkButton" id="cancel_button">
<                 <property name="can_default">yes</property>
<                 <property name="can_focus">yes</property>
<                 <property name="relief">GTK_RELIEF_NORMAL</property>
<                 <property name="visible">yes</property>
<                 <property name="label">gtk-cancel</property>
<                 <property name="use_stock">yes</property>
<                 <property name="use_underline">yes</property>
< 
<                 <signal name="clicked" handler="on_cancel_button_clicked" />
<               </widget>
<             </child>
< 
<             <child>
<               <widget class="GtkButton" id="ok_button">
<                 <property name="can_default">yes</property>
<                 <property name="can_focus">yes</property>
<                 <property name="relief">GTK_RELIEF_NORMAL</property>
<                 <property name="visible">yes</property>
<                 <property name="label">gtk-ok</property>
<                 <property name="use_stock">yes</property>
<                 <property name="use_underline">yes</property>
< 
<                 <signal name="clicked" handler="on_ok_button_clicked" />
<               </widget>
<             </child>
<           </widget>
<           <packing>
<             <property name="padding">0</property>
<             <property name="expand">no</property>
<             <property name="fill">no</property>
<           </packing>
<         </child>
<       </widget>
<     </child>
<   </widget>
