GnuCash  4.12-404-geb24099a91
Data Structures | Typedefs | Functions
Options Dialog

Data Structures

class  GncOptionsDialog
 

Typedefs

typedef void(* GncOptionsDialogCallback) (GncOptionsDialog *, void *data)
 

Functions

void gnc_business_options_gnome_initialize (void)
 Set up the business and counters pages in the File Preferences dialog.
 
void gnc_options_dialog_set_new_book_option_values (GncOptionDB *odb)
 Set the initial values of new book options to values specified in user preferences. More...
 

Detailed Description

Function Documentation

◆ gnc_options_dialog_set_new_book_option_values()

void gnc_options_dialog_set_new_book_option_values ( GncOptionDB odb)

Set the initial values of new book options to values specified in user preferences.

Nothing to do with GncOptionsDialog, but it depends on Gtk and s used in both assistant-hierarchy and gnc-main-window.

Parameters
odbThe book's options database.

Definition at line 680 of file dialog-options.cpp.

681 {
682  if (!odb) return;
683  auto num_split_action = gnc_prefs_get_bool(GNC_PREFS_GROUP_GENERAL,
684  GNC_PREF_NUM_SOURCE);
685  if (num_split_action)
686  {
687  auto option{odb->find_option(OPTION_SECTION_ACCOUNTS,
688  OPTION_NAME_NUM_FIELD_SOURCE)};
689  auto num_source_button{option_get_gtk_widget(option)};
690  gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (num_source_button),
691  num_split_action);
692  }
693 }
gboolean gnc_prefs_get_bool(const gchar *group, const gchar *pref_name)
Get a boolean value from the preferences backend.