Peasyscan patches from rcrsn51.

diff -ur sane-frontends-1.0.14/src/preview.c sane-frontends-1.0.14-peasyscan/src/preview.c
--- sane-frontends-1.0.14/src/preview.c	2005-04-16 20:12:07.000000000 +0700
+++ sane-frontends-1.0.14-peasyscan/src/preview.c	2013-02-27 07:56:42.000000000 +0700
@@ -88,6 +88,9 @@
 #define BACKEND_NAME preview
 #include "../include/sane/sanei_debug.h"
 
+#include <locale.h>
+#include <libintl.h>
+
 #ifndef PATH_MAX
 # define PATH_MAX	1024
 #endif
@@ -1273,16 +1276,20 @@
   preview_update (p);
 
   /* fill in action area: */
+  
+  setlocale( LC_ALL, "" );
+bindtextdomain( "peasyscan", "/usr/share/locale" );
+textdomain ("peasyscan");
 
   /* Preview button */
-  p->preview = gtk_button_new_with_label ("Acquire Preview");
+  p->preview = gtk_button_new_with_label (gettext("Acquire Preview"));
   gtk_signal_connect (GTK_OBJECT (p->preview), "clicked",
 		      (GtkSignalFunc) start_button_clicked, p);
   gtk_box_pack_start (GTK_BOX (hbox), p->preview, TRUE, TRUE, 0);
   gtk_widget_show (p->preview);
 
   /* Cancel button */
-  p->cancel = gtk_button_new_with_label ("Cancel Preview");
+  p->cancel = gtk_button_new_with_label (gettext("Cancel Preview"));
   gtk_signal_connect (GTK_OBJECT (p->cancel), "clicked",
 		      (GtkSignalFunc) cancel_button_clicked, p);
   gtk_box_pack_start (GTK_BOX (hbox), p->cancel, TRUE, TRUE, 0);
diff -ur sane-frontends-1.0.14/src/xscanimage.c sane-frontends-1.0.14-peasyscan/src/xscanimage.c
--- sane-frontends-1.0.14/src/xscanimage.c	2005-04-16 20:12:07.000000000 +0700
+++ sane-frontends-1.0.14-peasyscan/src/xscanimage.c	2013-02-27 07:54:30.000000000 +0700
@@ -52,6 +52,10 @@
 #include <preferences.h>
 #include <preview.h>
 
+#include <locale.h>
+#include <libintl.h>
+
+
 #ifndef PATH_MAX
 # define PATH_MAX	1024
 #endif
@@ -95,6 +99,8 @@
 		 int *nreturn_vals, GimpParam ** return_vals);
 #endif /* !ENABLE_GIMP_1_2 */
 
+
+
 GimpPlugInInfo PLUG_IN_INFO = {
   NULL,				/* init_proc */
   NULL,				/* quit_proc */
@@ -124,6 +130,7 @@
   GtkWidget *info_label;
   GtkWidget *preview_button;
   GtkWidget *scan_button;
+  GtkWidget *done_button;
   Preview *preview;
   gint32 mode;
   /* various scanning related state: */
@@ -1825,11 +1832,11 @@
       gtk_signal_connect (GTK_OBJECT (button), "clicked",
 			  (GtkSignalFunc) browse_filename_callback, 0);
 
-      gtk_widget_show (button);
+   /*   gtk_widget_show (button);
       gtk_widget_show (label);
-      gtk_widget_show (text);
+      gtk_widget_show (text); 
       gtk_widget_show (hbox);
-      gtk_widget_show (frame);
+      gtk_widget_show (frame); */
     }
 
   /* create  a subwindow so the dialog keeps its position on rebuilds: */
@@ -1876,21 +1883,30 @@
   /* The bottom row of buttons */
   hbox = GTK_DIALOG (scan_win.shell)->action_area;
 
-  /* The Scan button */
-  scan_win.scan_button = gtk_button_new_with_label ("Scan");
-  gtk_signal_connect (GTK_OBJECT (scan_win.scan_button), "clicked",
-		      (GtkSignalFunc) scan_dialog, NULL);
-  gtk_box_pack_start (GTK_BOX (hbox), scan_win.scan_button, TRUE, TRUE, 0);
-  gtk_widget_show (scan_win.scan_button);
-
+  
   /* The Preview button */
   scan_win.preview_button =
-    gtk_toggle_button_new_with_label ("Preview Window");
+    gtk_toggle_button_new_with_label (gettext("Preview"));
   gtk_signal_connect (GTK_OBJECT (scan_win.preview_button), "clicked",
 		      (GtkSignalFunc) scan_preview, NULL);
   gtk_box_pack_start (GTK_BOX (hbox), scan_win.preview_button, TRUE, TRUE, 0);
   gtk_widget_show (scan_win.preview_button);
 
+/* The Scan button */
+  scan_win.scan_button = gtk_button_new_with_label (gettext("Scan"));
+  gtk_signal_connect (GTK_OBJECT (scan_win.scan_button), "clicked",
+		      (GtkSignalFunc) scan_dialog, NULL);
+  gtk_box_pack_start (GTK_BOX (hbox), scan_win.scan_button, TRUE, TRUE, 0);
+  gtk_widget_show (scan_win.scan_button);
+  
+/* The Done button */
+  scan_win.done_button = gtk_button_new_with_label (gettext("Return"));
+  gtk_signal_connect (GTK_OBJECT (scan_win.done_button), "clicked",
+		      (GtkSignalFunc) files_exit_callback, 0);
+  gtk_box_pack_start (GTK_BOX (hbox), scan_win.done_button, TRUE, TRUE, 0);
+  gtk_widget_show (scan_win.done_button);
+
+
 #if 0
   /* The Zoom in button */
   button = gtk_button_new_with_label ("Zoom");
@@ -2189,6 +2205,10 @@
     ++prog_name;
   else
     prog_name = argv[0];
+    
+    setlocale( LC_ALL, "" );
+bindtextdomain( "peasyscan", "/usr/share/locale" );
+textdomain ("peasyscan");
 
 #ifdef HAVE_LIBGIMP_GIMP_H
   {
