[PATCH] Print_c Make colorButton remember last state during session

Salvador Cuñat salvador.cunat at gmail.com
Wed Mar 20 12:30:57 PDT 2013


While colorButton defaults to "color" in first access to print menu, it seems
preferable to keep the last state selected by the user.  At least until exit session.

Signed-off-by: Salvador Cuñat <salvador.cunat at gmail.com>
---
 print.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/print.c b/print.c
index bf1ef9f..beb6bcc 100644
--- a/print.c
+++ b/print.c
@@ -986,7 +986,7 @@ static GtkWidget *print_dialog(GtkPrintOperation *operation, gpointer user_data)
 	colorButton = gtk_check_button_new_with_label(_("Print in color"));
 	g_signal_connect(G_OBJECT(colorButton), "toggled",
 		G_CALLBACK(color_selection_toggle), NULL);
-	gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(colorButton),TRUE);
+	gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(colorButton),print_options.color_selected);
 	gtk_box_pack_start(GTK_BOX(box), colorButton, FALSE, FALSE, 2);
 
 	frame1 = gtk_frame_new(_("Ordering"));
-- 
1.7.10.4



More information about the subsurface mailing list