From 595514ed61e4308fddaada3954a930833d6744c7 Mon Sep 17 00:00:00 2001 From: Sven Neumann Date: Sun, 14 Mar 1999 17:03:58 +0000 Subject: [PATCH] Correctly set the chain_button in the monitor section. --Sven --- ChangeLog | 5 +++++ app/dialogs/preferences-dialog.c | 6 +++--- app/gui/preferences-dialog.c | 6 +++--- app/preferences_dialog.c | 6 +++--- 4 files changed, 14 insertions(+), 9 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1ba798ed22..40b77ff9de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun Mar 14 17:56:14 MET 1999 Sven Neumann + + * app/preferences_dialog.c: correctly set the status of the + chain_button in the monitors section when creating the dialog + Sun Mar 14 13:26:11 MET 1999 Sven Neumann * app/app_procs.c: reverted Michaels change as it is defintely diff --git a/app/dialogs/preferences-dialog.c b/app/dialogs/preferences-dialog.c index 9440fdcb6c..06d290d6af 100644 --- a/app/dialogs/preferences-dialog.c +++ b/app/dialogs/preferences-dialog.c @@ -1812,7 +1812,6 @@ file_pref_cmd_callback (GtkWidget *widget, gtk_widget_show (vbox); monitor_resolution_force_equal = gimp_chain_button_new (GIMP_CHAIN_BOTTOM); - monitor_resolution_sizeentry = gimp_size_entry_new (2, UNIT_INCH, "%s", FALSE, TRUE, 75, GIMP_SIZE_ENTRY_UPDATE_RESOLUTION); @@ -1844,8 +1843,9 @@ file_pref_cmd_callback (GtkWidget *widget, TRUE, TRUE, 0); gtk_widget_show (monitor_resolution_sizeentry); - gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), - TRUE); + if (ABS (monitor_xres - monitor_yres) < 1e-5) + gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), + TRUE); gtk_table_attach_defaults (GTK_TABLE (monitor_resolution_sizeentry), monitor_resolution_force_equal, 1, 3, 3, 4); gtk_widget_show (monitor_resolution_force_equal); diff --git a/app/gui/preferences-dialog.c b/app/gui/preferences-dialog.c index 9440fdcb6c..06d290d6af 100644 --- a/app/gui/preferences-dialog.c +++ b/app/gui/preferences-dialog.c @@ -1812,7 +1812,6 @@ file_pref_cmd_callback (GtkWidget *widget, gtk_widget_show (vbox); monitor_resolution_force_equal = gimp_chain_button_new (GIMP_CHAIN_BOTTOM); - monitor_resolution_sizeentry = gimp_size_entry_new (2, UNIT_INCH, "%s", FALSE, TRUE, 75, GIMP_SIZE_ENTRY_UPDATE_RESOLUTION); @@ -1844,8 +1843,9 @@ file_pref_cmd_callback (GtkWidget *widget, TRUE, TRUE, 0); gtk_widget_show (monitor_resolution_sizeentry); - gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), - TRUE); + if (ABS (monitor_xres - monitor_yres) < 1e-5) + gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), + TRUE); gtk_table_attach_defaults (GTK_TABLE (monitor_resolution_sizeentry), monitor_resolution_force_equal, 1, 3, 3, 4); gtk_widget_show (monitor_resolution_force_equal); diff --git a/app/preferences_dialog.c b/app/preferences_dialog.c index 9440fdcb6c..06d290d6af 100644 --- a/app/preferences_dialog.c +++ b/app/preferences_dialog.c @@ -1812,7 +1812,6 @@ file_pref_cmd_callback (GtkWidget *widget, gtk_widget_show (vbox); monitor_resolution_force_equal = gimp_chain_button_new (GIMP_CHAIN_BOTTOM); - monitor_resolution_sizeentry = gimp_size_entry_new (2, UNIT_INCH, "%s", FALSE, TRUE, 75, GIMP_SIZE_ENTRY_UPDATE_RESOLUTION); @@ -1844,8 +1843,9 @@ file_pref_cmd_callback (GtkWidget *widget, TRUE, TRUE, 0); gtk_widget_show (monitor_resolution_sizeentry); - gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), - TRUE); + if (ABS (monitor_xres - monitor_yres) < 1e-5) + gimp_chain_button_set_active (GIMP_CHAIN_BUTTON (monitor_resolution_force_equal), + TRUE); gtk_table_attach_defaults (GTK_TABLE (monitor_resolution_sizeentry), monitor_resolution_force_equal, 1, 3, 3, 4); gtk_widget_show (monitor_resolution_force_equal);