1 /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4 c-style: "K&R" -*- */
3 /*----------------------------------------------------------------------
5 gpiv - Graphic program for Particle Image Velocimetry, based on gtk/gnome
8 Copyright (C) 2002, 2003, 2004 Gerber van der Graaf
10 This file is part of gpiv.
12 Gpiv is free software; you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 2, or (at your option)
17 This program is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU General Public License for more details.
22 You should have received a copy of the GNU General Public License
23 along with this program; if not, write to the Free Software Foundation,
24 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26 ----------------------------------------------------------------------*/
29 * $Log: preferences.c,v $
30 * Revision 1.17 2008-04-28 12:00:58 gerber
31 * hdf-formatted files are now with .hdf extension (previously: .gpi)
33 * Revision 1.16 2007-12-19 08:42:35 gerber
36 * Revision 1.15 2007-11-23 16:24:08 gerber
37 * release 0.5.0: Kafka
39 * Revision 1.14 2007-03-22 16:00:32 gerber
40 * Added image processing tabulator
42 * Revision 1.13 2007/02/05 15:17:09 gerber
43 * auto stretching, broadcast display settings to buffers from preferences
45 * Revision 1.12 2007-01-29 11:27:44 gerber
46 * added image formats png, gif, tif png, bmp, improved buffer display
48 * Revision 1.11 2006-09-18 07:27:06 gerber
49 * *** empty log message ***
51 * Revision 1.10 2006/01/31 14:28:13 gerber
54 * Revision 1.8 2005/01/19 15:53:42 gerber
55 * Initiation of Data Acquisition (DAC); trigerring of lasers and camera
56 * by using RTAI and Realtime Linux, recording images from IEEE1394
57 * (Firewire) IIDC compliant camera's
59 * Revision 1.7 2004/10/15 19:24:05 gerber
60 * GPIV_ and Gpiv prefix to defines and structure names of libgpiv
62 * Revision 1.6 2004/06/14 21:19:23 gerber
63 * Image depth up to 16 bits.
64 * Improvement "single int" and "drag int" in Eval tab.
65 * Viewer's pop-up menu.
66 * Adaption for gpiv_matrix_* and gpiv_vector_*.
68 * See Changelog for further info.
70 * Revision 1.5 2003/09/01 11:17:15 gerber
71 * improved monitoring of interrogation process
73 * Revision 1.4 2003/08/22 15:24:52 gerber
74 * interactive spatial scaling
76 * Revision 1.3 2003/07/25 15:40:24 gerber
77 * removed/disabled setting of correlation in Eval tab, Correlation type in Image info tab
79 * Revision 1.2 2003/06/27 13:47:26 gerber
80 * display ruler, line/point evaluation
82 * Revision 1.1.1.1 2003/06/17 17:10:52 gerber
89 #endif /* HAVE_CONFIG_H */
94 #include "preferences.h"
95 #include "preferences_interface.h"
99 apply_gpivpar_console (GpivConsole
* gpiv
);
102 apply_gpivpar_display ();
106 on_checkbutton_gpivbuttons_activate(GtkWidget
*widget
,
109 /*-----------------------------------------------------------------------------
112 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
113 default_par
->console__view_gpivbuttons
= 1;
115 default_par
->console__view_gpivbuttons
= 0;
122 on_checkbutton_tab_activate(GtkWidget
*widget
,
125 /*-----------------------------------------------------------------------------
128 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
129 default_par
->console__view_tabulator
= 1;
131 default_par
->console__view_tabulator
= 0;
138 on_checkbutton_hdf_activate(GtkWidget
*widget
,
141 /*-----------------------------------------------------------------------------
144 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
145 default_par
->hdf
= 1;
147 default_par
->hdf
= 0;
154 on_radiobutton_datafmt(GtkWidget
*widget
,
157 /*-----------------------------------------------------------------------------
160 gint select
= atoi(gtk_object_get_data(GTK_OBJECT(widget
),
162 default_par
->hdf
= select
;
163 if (gpiv_par
->verbose
) g_message("on_radiobutton_datafmt:: %d", default_par
->hdf
);
169 on_radiobutton_imgfmt(GtkWidget
*widget
,
172 /*-----------------------------------------------------------------------------
175 gint fmt_select
= atoi(gtk_object_get_data(GTK_OBJECT(widget
),
177 gpiv_par
->img_fmt
= fmt_select
;
179 if (fmt_select
== IMG_FMT_PNG
) {
180 if (gpiv_par
->verbose
) g_message("on_radiobutton_imgfmt:: img_fmt = IMG_FMT_PNG");
181 } else if (fmt_select
== IMG_FMT_HDF
) {
182 if (gpiv_par
->verbose
) g_message("on_radiobutton_imgfmt:: img_fmt = IMG_FMT_HDF");
183 } else if (fmt_select
== IMG_FMT_RAW
) {
184 if (gpiv_par
->verbose
) g_message("on_radiobutton_imgfmt:: img_fmt = IMG_FMT_RAW");
186 g_message("INVALID IMG_FMT");
193 on_checkbutton_xcorr_activate(GtkWidget
*widget
,
196 /*-----------------------------------------------------------------------------
199 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
200 default_par
->x_corr
= 1;
202 default_par
->x_corr
= 0;
209 on_checkbutton_tooltips_activate(GtkWidget
*widget
,
212 /*-----------------------------------------------------------------------------
215 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
216 default_par
->console__show_tooltips
= 1;
218 default_par
->console__show_tooltips
= 0;
226 on_checkbutton_process_cam_activate(GtkWidget
*widget
,
229 /*-----------------------------------------------------------------------------
232 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
233 default_par
->process__cam
= TRUE
;
235 default_par
->process__cam
= FALSE
;
238 #endif /* ENABLE_CAM */
243 on_checkbutton_process_trig_activate(GtkWidget
*widget
,
246 /*-----------------------------------------------------------------------------
249 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
250 default_par
->process__trig
= TRUE
;
252 default_par
->process__trig
= FALSE
;
255 #endif /* ENABLE_TRIG */
258 #ifdef ENABLE_IMGPROC
260 on_checkbutton_process_imgproc_activate(GtkWidget
*widget
,
263 /*-----------------------------------------------------------------------------
266 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
267 default_par
->process__imgproc
= TRUE
;
269 default_par
->process__imgproc
= FALSE
;
272 #endif /* ENABLE_IMGPROC */
276 on_checkbutton_process_piv_activate(GtkWidget
*widget
,
279 /*-----------------------------------------------------------------------------
282 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
283 default_par
->process__piv
= TRUE
;
285 default_par
->process__piv
= FALSE
;
292 on_checkbutton_process_gradient_activate(GtkWidget
*widget
,
295 /*-----------------------------------------------------------------------------
298 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
299 default_par
->process__gradient
= TRUE
;
301 default_par
->process__gradient
= FALSE
;
308 on_checkbutton_process_resstats_activate(GtkWidget
*widget
,
311 /*-----------------------------------------------------------------------------
314 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
315 default_par
->process__resstats
= TRUE
;
317 default_par
->process__resstats
= FALSE
;
324 on_checkbutton_process_errvec_activate(GtkWidget
*widget
,
327 /*-----------------------------------------------------------------------------
330 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
331 default_par
->process__errvec
= TRUE
;
333 default_par
->process__errvec
= FALSE
;
340 on_checkbutton_process_peaklck_activate(GtkWidget
*widget
,
343 /*-----------------------------------------------------------------------------
346 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
347 default_par
->process__peaklock
= TRUE
;
349 default_par
->process__peaklock
= FALSE
;
356 on_checkbutton_process_subtract_activate(GtkWidget
*widget
,
359 /*-----------------------------------------------------------------------------
362 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
363 default_par
->process__subtract
= TRUE
;
365 default_par
->process__subtract
= FALSE
;
372 on_checkbutton_process_scale_activate(GtkWidget
*widget
,
375 /*-----------------------------------------------------------------------------
378 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
379 default_par
->process__scale
= TRUE
;
381 default_par
->process__scale
= FALSE
;
388 on_checkbutton_process_avg_activate(GtkWidget
*widget
,
391 /*-----------------------------------------------------------------------------
394 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
395 default_par
->process__average
= TRUE
;
397 default_par
->process__average
= FALSE
;
404 on_checkbutton_process_vorstra_activate(GtkWidget
*widget
,
407 /*-----------------------------------------------------------------------------
410 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
411 default_par
->process__vorstra
= TRUE
;
413 default_par
->process__vorstra
= FALSE
;
420 on_spinbutton_bins_activate(GtkWidget
*widget
,
423 /*-----------------------------------------------------------------------------
430 on_radiobutton_display_vecscale(GtkWidget
*widget
,
433 /*-----------------------------------------------------------------------------
436 default_par
->display__vector_scale
=
437 atoi(gtk_object_get_data(GTK_OBJECT(widget
),
444 on_radiobutton_display_veccolor(GtkWidget
*widget
,
447 /*-----------------------------------------------------------------------------
450 default_par
->display__vector_color
=
451 atoi(gtk_object_get_data(GTK_OBJECT(widget
),
458 on_radiobutton_display_zoomscale(GtkWidget
*widget
,
461 /*-----------------------------------------------------------------------------
464 default_par
->display__zoom_index
=
465 atoi(gtk_object_get_data(GTK_OBJECT(widget
),
472 on_radiobutton_display_background(GtkWidget
*widget
,
475 /*-----------------------------------------------------------------------------
478 default_par
->display__backgrnd
=
479 atoi (gtk_object_get_data (GTK_OBJECT (widget
), "bgcolor"));
480 if (gpiv_par
->verbose
) g_message ("on_radiobutton_display_background:: display__backgrnd = %d",
481 default_par
->display__backgrnd
);
487 on_checkbutton_display_display_intregs(GtkWidget
*widget
,
490 /*-----------------------------------------------------------------------------
494 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
495 default_par
->display__intregs
= TRUE
;
497 default_par
->display__intregs
= FALSE
;
504 on_checkbutton_display_display_piv(GtkWidget
*widget
,
507 /*-----------------------------------------------------------------------------
510 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
511 default_par
->display__piv
= TRUE
;
513 default_par
->display__piv
= FALSE
;
520 on_radiobutton_display_scalar(GtkWidget
*widget
,
523 /*-----------------------------------------------------------------------------
526 default_par
->display__scalar
=
527 atoi (gtk_object_get_data (GTK_OBJECT (widget
), "scalar"));
528 if (gpiv_par
->verbose
) g_message ("on_radiobutton_display_scalar:: display__scalar = %d",
529 default_par
->display__scalar
);
535 on_checkbutton_display_view_menubar_activate (GtkWidget
*widget
,
538 /*-----------------------------------------------------------------------------
541 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
542 default_par
->display__view_menubar
= 1;
544 default_par
->display__view_menubar
= 0;
551 on_checkbutton_display_view_rulers_activate (GtkWidget
*widget
,
554 /*-----------------------------------------------------------------------------
557 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
558 default_par
->display__view_rulers
= 1;
560 default_par
->display__view_rulers
= 0;
567 on_checkbutton_display_stretch_auto_activate (GtkWidget
*widget
,
570 /*-----------------------------------------------------------------------------
573 if (GTK_TOGGLE_BUTTON(widget
)->active
) {
574 default_par
->display__stretch_auto
= TRUE
;
576 default_par
->display__stretch_auto
= FALSE
;
583 on_preferences_response(GtkDialog
*dialog
,
587 /*-----------------------------------------------------------------------------
590 GpivConsole
*gpiv
= gtk_object_get_data(GTK_OBJECT(dialog
), "gpiv");
591 Pref
*pref
= gtk_object_get_data(GTK_OBJECT(dialog
), "pref");
592 g_assert( response
== GTK_RESPONSE_OK
593 || response
== GTK_RESPONSE_APPLY
594 || response
== GTK_RESPONSE_CANCEL
);
597 case GTK_RESPONSE_OK
:
600 gtk_widget_destroy(GTK_WIDGET (dialog
));
603 case GTK_RESPONSE_APPLY
:
607 case GTK_RESPONSE_CANCEL
:
608 gtk_widget_destroy(GTK_WIDGET (dialog
));
612 g_warning("on_preferences_response: should not arrive here");
621 apply_gpivpar (GpivConsole
* gpiv
)
622 /* ----------------------------------------------------------------------------
623 * Updates actual parameters
628 apply_gpivpar_console(gpiv
);
630 for (i
= 0; i
< nbufs
; i
++) {
631 display_act
= display
[i
];
632 if (display_act
!= NULL
) {
633 if (gpiv_par
->verbose
) g_message("apply_gpivpar:: ibuf = %d apply_gpivpar_display", i
);
634 apply_gpivpar_display ();
640 apply_gpivpar_console(GpivConsole
*gpiv
)
641 /* ----------------------------------------------------------------------------
642 * Updates actual parameters for the console
645 GtkWidget
*settings_menu_gpiv0
=
646 gtk_object_get_data (GTK_OBJECT (gpiv
->console
), "settings_menu_gpiv0");
647 GtkWidget
*settings_menu_gpiv1
=
648 gtk_object_get_data (GTK_OBJECT (gpiv
->console
), "settings_menu_gpiv1");
649 GtkWidget
*help_menu_gpiv0
=
650 gtk_object_get_data (GTK_OBJECT (gpiv
->console
), "help_menu_gpiv0");
651 GtkWidget
*help_menu_gpiv_popup0
=
652 gtk_object_get_data (GTK_OBJECT (gpiv
->console
), "help_menu_gpiv_popup0");
655 parameters_set(gpiv_par
, FALSE
);
656 cp_undef_parameters(default_par
, gpiv_par
);
659 if (default_par
->console__view_gpivbuttons
== 1) {
660 gtk_widget_show(gpiv
->handlebox1
);
661 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
662 (settings_menu_gpiv0
), TRUE
);
664 gtk_widget_hide(gpiv
->handlebox1
);
665 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
666 (settings_menu_gpiv0
), FALSE
);
669 if (default_par
->console__view_tabulator
== 1) {
670 gtk_widget_show(gpiv
->notebook
);
671 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
672 (settings_menu_gpiv1
), TRUE
);
674 gtk_widget_hide(gpiv
->notebook
);
675 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
676 (settings_menu_gpiv1
), FALSE
);
679 if (default_par
->console__show_tooltips
== 1) {
680 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
681 (help_menu_gpiv0
), TRUE
);
682 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
683 (help_menu_gpiv_popup0
), TRUE
);
685 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
686 (help_menu_gpiv0
), FALSE
);
687 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM
688 (help_menu_gpiv_popup0
), FALSE
);
691 gtk_spin_button_set_value(GTK_SPIN_BUTTON
692 (gpiv
->pivvalid
->spinbutton_histo_bins
),
693 default_par
->console__nbins
);
699 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON
700 (gpiv
->button_toolbar_cam
),
701 default_par
->process__cam
);
702 #endif /* ENABLE_CAM */
705 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON
706 (gpiv
->button_toolbar_trig
),
707 default_par
->process__trig
);
708 #endif /* ENABLE_TRIG */
710 #ifdef ENABLE_IMGPROC
711 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON
712 (gpiv
->button_toolbar_imgproc
),
713 default_par
->process__imgproc
);
714 #endif /* ENABLE_IMGPROC */
716 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON
717 (gpiv
->button_toolbar_piv
),
718 default_par
->process__piv
);
720 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
721 (gpiv
->button_toolbar_gradient
),
722 default_par
->process__gradient
);
724 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
725 (gpiv
->button_toolbar_resstats
),
726 default_par
->process__resstats
);
728 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
729 (gpiv
->button_toolbar_errvec
),
730 default_par
->process__errvec
);
732 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
733 (gpiv
->button_toolbar_peaklock
),
734 default_par
->process__peaklock
);
736 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
737 (gpiv
->button_toolbar_scale
),
738 default_par
->process__scale
);
740 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
741 (gpiv
->button_toolbar_average
),
742 default_par
->process__average
);
744 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
745 (gpiv
->button_toolbar_subavg
),
746 default_par
->process__subtract
);
748 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON
749 (gpiv
->button_toolbar_vorstra
),
750 default_par
->process__vorstra
);
756 apply_gpivpar_display (void)
757 /* ----------------------------------------------------------------------------
758 * Updates actual parameters for the actual display
761 GtkWidget
*view_menubar_popup_menu
=
762 gtk_object_get_data(GTK_OBJECT(display_act
->mwin
),
763 "view_menubar_popup_menu");
764 GtkWidget
*view_rulers_popup_menu
=
765 gtk_object_get_data(GTK_OBJECT(display_act
->mwin
),
766 "view_rulers_popup_menu");
768 GtkWidget
*stretch_auto_popup_menu
=
769 gtk_object_get_data(GTK_OBJECT(display_act
->mwin
),
770 "stretch_auto_popup_menu");
774 /* for (i = 0; i < nbufs; i++) { */
775 /* display_act = display[i]; */
776 /* if (display_act != NULL) { */
777 if (display_act
->pida
->exist_piv
778 && display_act
->display_piv
) {
779 update_all_vectors(display_act
->pida
);
783 if (display_act
->display_intregs
) {
784 if (default_par
->display__intregs
== 1) {
785 create_all_intregs2(display_act
);
786 create_all_intregs1(display_act
);
788 hide_all_intregs1(display_act
);
789 hide_all_intregs2(display_act
);
794 if (display_act
->pida
->exist_piv
) {
795 if (default_par
->display__piv
) {
796 create_all_vectors(display_act
->pida
);
798 hide_all_vectors(display_act
->pida
);
803 if (display_act
->pida
->exist_vor
) {
804 if (default_par
->display__scalar
== SHOW_SC_VORTICITY
) {
805 create_all_scalars (display_act
, GPIV_VORTICITY
);
807 hide_all_scalars (display_act
, GPIV_VORTICITY
);
812 if (display_act
->pida
->exist_sstrain
) {
813 if (default_par
->display__scalar
== SHOW_SC_SSTRAIN
) {
814 create_all_scalars (display_act
, GPIV_S_STRAIN
);
816 hide_all_scalars (display_act
, GPIV_S_STRAIN
);
821 if (display_act
->pida
->exist_nstrain
) {
822 if (default_par
->display__scalar
== SHOW_SC_NSTRAIN
) {
823 create_all_scalars (display_act
, GPIV_N_STRAIN
);
825 hide_all_scalars (display_act
, GPIV_N_STRAIN
);
829 if (default_par
->display__view_menubar
== 1) {
830 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
831 (view_menubar_popup_menu
),
834 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
835 (view_menubar_popup_menu
),
839 if (default_par
->display__view_rulers
== 1) {
840 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
841 (view_rulers_popup_menu
),
844 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
845 (view_rulers_popup_menu
),
849 if (default_par
->display__stretch_auto
== TRUE
) {
850 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
851 (stretch_auto_popup_menu
),
854 gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM
855 (stretch_auto_popup_menu
),
864 store_defaultpar (void
866 /* ----------------------------------------------------------------------------
867 * Store parameters as defaults
870 gnome_config_push_prefix ("/gpiv/General/");
871 /* gnome_config_set_bool ("print_par", print_par); */
872 gnome_config_set_bool ("console__show_tooltips", default_par
->console__show_tooltips
);
873 gnome_config_set_bool ("console__view_gpivbuttons", default_par
->console__view_gpivbuttons
);
874 gnome_config_set_bool ("console__view_tabulator", default_par
->console__view_tabulator
);
875 gnome_config_set_int ("console__nbins", default_par
->console__nbins
);
877 gnome_config_set_bool ("img_fmt", default_par
->img_fmt
);
878 gnome_config_set_bool ("hdf", default_par
->hdf
);
881 gnome_config_pop_prefix ();
882 gnome_config_push_prefix ("/gpiv/Image/");
883 gnome_config_set_bool ("x_corr", default_par
->x_corr
);
886 gnome_config_pop_prefix ();
887 gnome_config_push_prefix ("/gpiv/Processes/");
889 gnome_config_set_bool ("process__cam", default_par
->process__cam
);
890 #endif /* ENABLE_CAM */
892 gnome_config_set_bool ("process__trig", default_par
->process__trig
);
893 #endif /* ENABLE_TRIG */
894 #ifdef ENABLE_IMGPROC
895 gnome_config_set_bool ("process__imgproc", default_par
->process__imgproc
);
896 #endif /* ENABLE_IMGPROC */
897 gnome_config_set_bool ("process__piv", default_par
->process__piv
);
898 gnome_config_set_bool ("process__gradient", default_par
->process__gradient
);
899 gnome_config_set_bool ("process__resstats", default_par
->process__resstats
);
900 gnome_config_set_bool ("process__errvec", default_par
->process__errvec
);
901 gnome_config_set_bool ("process__peaklock", default_par
->process__peaklock
);
902 gnome_config_set_bool ("process__scale", default_par
->process__scale
);
903 gnome_config_set_bool ("process__average", default_par
->process__average
);
904 gnome_config_set_bool ("process__subtract", default_par
->process__subtract
);
905 gnome_config_set_bool ("process__vorstra", default_par
->process__vorstra
);
908 gnome_config_pop_prefix ();
909 gnome_config_push_prefix ("/gpiv/Display/");
910 gnome_config_set_bool ("display__view_menubar", default_par
->display__view_menubar
);
911 gnome_config_set_bool ("display__view_rulers", default_par
->display__view_rulers
);
912 gnome_config_set_bool ("display__stretch_auto", default_par
->display__stretch_auto
);
913 gnome_config_set_int ("display__vector_scale", default_par
->display__vector_scale
);
914 gnome_config_set_int ("display__vector_color", default_par
->display__vector_color
);
915 gnome_config_set_int ("display__zoom_index", default_par
->display__zoom_index
);
916 gnome_config_set_int ("display__backgrnd", default_par
->display__backgrnd
);
917 gnome_config_set_bool ("display__intregs", default_par
->display__intregs
);
918 gnome_config_set_bool ("display__piv", default_par
->display__piv
);
919 gnome_config_set_int ("display__scalar", default_par
->display__scalar
);
921 gnome_config_pop_prefix ();
922 gnome_config_sync ();