Index: src/eog-print-image-setup.c
===================================================================
--- src/eog-print-image-setup.c	(revision 4912)
+++ src/eog-print-image-setup.c	(working copy)
@@ -1041,3 +1041,40 @@
 	*scale = gtk_range_get_value (GTK_RANGE (priv->scaling));
 	*unit = priv->current_unit;
 }
+
+void
+eog_print_image_setup_update (GtkPrintOperation *operation,
+			      GtkWidget         *custom_widget,
+			      GtkPageSetup      *page_setup,
+			      GtkPrintSettings  *print_settings,
+			      gpointer           user_data)
+{
+	GtkWidget *preview;
+	gdouble    pos_x;
+	gdouble    pos_y;
+	EogPrintImageSetup *setup;
+
+	setup = EOG_PRINT_IMAGE_SETUP (custom_widget);
+
+	if (page_setup)
+		{
+			g_object_unref (setup->priv->page_setup);
+			setup->priv->page_setup = gtk_page_setup_copy (page_setup);
+		}
+	else
+		setup->priv->page_setup = gtk_page_setup_copy (page_setup);
+
+	set_initial_values (EOG_PRINT_IMAGE_SETUP (setup));
+
+	preview = EOG_PRINT_IMAGE_SETUP (setup)->priv->preview;
+	eog_print_preview_set_from_page_setup (EOG_PRINT_PREVIEW (preview),
+					       setup->priv->page_setup);
+
+	pos_x = gtk_spin_button_get_value (GTK_SPIN_BUTTON (setup->priv->left));
+	pos_y = gtk_spin_button_get_value (GTK_SPIN_BUTTON (setup->priv->top));
+	if (setup->priv->current_unit == GTK_UNIT_MM) {
+		pos_x *= FACTOR_MM_TO_INCH;
+		pos_y *= FACTOR_MM_TO_INCH;
+	}
+	eog_print_preview_set_image_position (EOG_PRINT_PREVIEW (setup->priv->preview), pos_x, pos_y);
+}
Index: src/eog-print-image-setup.h
===================================================================
--- src/eog-print-image-setup.h	(revision 4912)
+++ src/eog-print-image-setup.h	(working copy)
@@ -57,6 +57,11 @@
 						     gdouble            *top,
 						     gdouble            *scale,
 						     GtkUnit            *unit);
+void              eog_print_image_setup_update      (GtkPrintOperation *operation,
+						     GtkWidget         *custom_widget,
+						     GtkPageSetup      *page_setup,
+						     GtkPrintSettings  *print_settings,
+						     gpointer           user_data);
 
 G_END_DECLS
 
Index: src/eog-window.c
===================================================================
--- src/eog-window.c	(revision 4912)
+++ src/eog-window.c	(working copy)
@@ -187,6 +187,8 @@
 
 	gboolean	     save_disabled;
 
+	GtkPageSetup        *page_setup;
+
 #ifdef HAVE_LCMS
         cmsHPROFILE         *display_profile;
 #endif
@@ -2238,22 +2240,16 @@
 static void
 eog_window_page_setup (EogWindow *window)
 {
-	GtkPageSetup *new_page_setup;
-	GtkPageSetup *page_setup;
 	GtkPrintSettings *print_settings;
 
 	eog_debug (DEBUG_PRINTING);
 
 	print_settings = eog_print_get_print_settings ();
-	page_setup = eog_print_get_page_setup ();
 
-	new_page_setup = gtk_print_run_page_setup_dialog (GTK_WINDOW (window),
-							  page_setup,
-							  print_settings);
-	eog_print_set_page_setup (new_page_setup);
+	window->priv->page_setup = gtk_print_run_page_setup_dialog (GTK_WINDOW (window),
+								    window->priv->page_setup,
+								    print_settings);
 
-	g_object_unref (page_setup);
-	g_object_unref (new_page_setup);
 	g_object_unref (print_settings);
 }
 
@@ -2270,11 +2266,15 @@
 	eog_debug (DEBUG_PRINTING);
 
 	print_settings = eog_print_get_print_settings ();
-	page_setup = eog_print_get_page_setup ();
 
 	/* Make sure the window stays valid while printing */
 	g_object_ref (window);
 
+	if (window->priv->page_setup != NULL)
+		page_setup = g_object_ref (window->priv->page_setup);
+	else
+		page_setup = NULL;
+
 	print = eog_print_operation_new (window->priv->image,
 					 print_settings,
 					 page_setup);
@@ -2297,8 +2297,8 @@
 	} else if (res == GTK_PRINT_OPERATION_RESULT_APPLY) {
 		eog_print_set_print_settings (gtk_print_operation_get_print_settings (print));
 	}
-
-	g_object_unref (page_setup);
+	if (page_setup != NULL)
+		g_object_unref (page_setup);
 	g_object_unref (print_settings);
 	g_object_unref (window);
 }
@@ -4237,6 +4237,8 @@
 	window->priv->collection_resizable = FALSE;
 
 	window->priv->save_disabled = FALSE;
+
+	window->priv->page_setup = NULL;
 }
 
 static void
Index: src/eog-print.c
===================================================================
--- src/eog-print.c	(revision 4912)
+++ src/eog-print.c	(working copy)
@@ -113,7 +113,8 @@
 
 	page_setup = gtk_print_operation_get_default_page_setup (operation);
 
-	g_assert (page_setup != NULL);
+	if (page_setup == NULL)
+		page_setup = gtk_page_setup_new ();
 
 	return G_OBJECT (eog_print_image_setup_new (data->image, page_setup));
 }
@@ -187,6 +188,9 @@
 	g_signal_connect (print, "create-custom-widget",
 			  G_CALLBACK (eog_print_create_custom_widget),
 			  data);
+	g_signal_connect (print, "update-custom-widget",
+			  G_CALLBACK (eog_print_image_setup_update),
+			  data);
 	g_signal_connect (print, "custom-widget-apply",
 			  G_CALLBACK (eog_print_custom_widget_apply),
 			  data);
