X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Foptions-dialog.c;h=1890f069f4481dd869fa4b0bdc745cf25b81d62a;hb=39e99af63f3280cd2d2d822eb2734371278de9df;hp=c50048060212a0c9e847dfd88414966a4d98e5e3;hpb=c8972f8c7c079984cc1986db8755e838f4050f9d;p=pspp diff --git a/src/ui/gui/options-dialog.c b/src/ui/gui/options-dialog.c index c500480602..1890f069f4 100644 --- a/src/ui/gui/options-dialog.c +++ b/src/ui/gui/options-dialog.c @@ -1,5 +1,5 @@ /* PSPPIRE - a graphical user interface for PSPP. - Copyright (C) 2017 Free Software Foundation + Copyright (C) 2017, 2021 Free Software Foundation This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -45,6 +45,8 @@ struct options_dialog GtkWidget *maximize; GtkWidget *alert; GtkWidget *raise; + + GtkWidget *show_tips; }; GType @@ -75,11 +77,14 @@ options_dialog (PsppireDataWindow *de) GtkWidget *dialog ; gboolean disp_labels = true; + gboolean show_tips = true; fd.xml = builder_new ("options.ui"); dialog = get_widget_assert (fd.xml, "options-dialog"); + fd.show_tips = get_widget_assert (fd.xml, "checkbutton-show-tips"); + fd.show_labels = get_widget_assert (fd.xml, "radiobutton-labels"); fd.show_names = get_widget_assert (fd.xml, "radiobutton-names"); @@ -105,6 +110,13 @@ options_dialog (PsppireDataWindow *de) !disp_labels); } + if (psppire_conf_get_boolean (fd.conf, + "startup", "show-user-tips", &show_tips)) + { + gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (fd.show_tips), + show_tips); + } + int what = -1; psppire_conf_get_enum (fd.conf, "VariableLists", "sort-order", @@ -182,6 +194,10 @@ options_dialog (PsppireDataWindow *de) psppire_conf_set_boolean (fd.conf, "OutputWindowAction", "alert", gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (fd.alert))); + + psppire_conf_set_boolean (fd.conf, "startup", "show-user-tips", + gtk_toggle_button_get_active + (GTK_TOGGLE_BUTTON (fd.show_tips))); } g_object_unref (fd.xml);