diff --git a/AUTHORS b/AUTHORS index a231172c0f..45d7d3afdd 100644 --- a/AUTHORS +++ b/AUTHORS @@ -141,6 +141,7 @@ Stefan Nobis German translation patch Peter Norton for a valiant attempt at a GTK port OmNiBuS web site graphics & content Gordon Oliver multiple currency status line patch +Alan Orndorff Solaris packager Myroslav Opyr for misc patches Dave Peticolas extensive intelligent patches Laurent P{'e}lecq i18n patches with gettext @@ -163,6 +164,7 @@ Robby Stephenson register & file history patches Christian Stimming report patch Bartek Szady engine and build system patches Herbert Thoma gnome register & euro support patches +Arnold Troeger Mandrake packager Diane Trout scheme QIF import patch Richard -Gilligan- Uschold tax report & txf export Richard Wackerbarth patch to gnc-prices, qif import fixes diff --git a/ChangeLog b/ChangeLog index 06132530d5..de8cfc78af 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +2001-06-05 Dave Peticolas + + * src/gnome/druid-commodity.c: use new func + + * src/gnome/new-user-funs.c: use new func + + * src/gnome/druid-qif-import.c: use new func + + * src/gnome/druid-utils.c (gnc_druid_set_colors): new func + + * doc/sgml/C/xacc-about.sgml: update credits + + * AUTHORS: update credits + 2001-06-04 Dave Peticolas * src/gnome/new-user.glade: tweak gui. fix strings. diff --git a/doc/sgml/C/xacc-about.sgml b/doc/sgml/C/xacc-about.sgml index 88fb9302d6..2bd8651b58 100644 --- a/doc/sgml/C/xacc-about.sgml +++ b/doc/sgml/C/xacc-about.sgml @@ -743,6 +743,14 @@ Nielsen + +dwarf@solarisresources.com Alan Orndorff + + +Solaris packager + + + mopyr@IPM.Lviv.UA Myroslav Opyr @@ -906,6 +914,13 @@ Nielsen + +troeger@samart.co.thArnold Troeger + +Mandrake packager + + + detrout@earthlink.net Diane Trout diff --git a/src/gnome/druid-commodity.c b/src/gnome/druid-commodity.c index 67d76fe9a9..e3b6b84cf5 100644 --- a/src/gnome/druid-commodity.c +++ b/src/gnome/druid-commodity.c @@ -33,6 +33,7 @@ #include "FileDialog.h" #include "druid-commodity.h" +#include "druid-utils.h" #include "dialog-commodity.h" #include "query-user.h" #include "gnc-commodity.h" @@ -188,6 +189,8 @@ gnc_ui_commodity_druid_create(const char * filename) { back_page = GNOME_DRUID_PAGE(new_page->page); } + gnc_druid_set_colors (GNOME_DRUID (d->druid)); + gtk_widget_show_all(d->window); g_list_free(orphans); diff --git a/src/gnome/druid-qif-import.c b/src/gnome/druid-qif-import.c index 54ebec1fb8..a355bc573d 100644 --- a/src/gnome/druid-qif-import.c +++ b/src/gnome/druid-qif-import.c @@ -38,6 +38,7 @@ #include "dialog-commodity.h" #include "dialog-utils.h" #include "druid-qif-import.h" +#include "druid-utils.h" #include "global-options.h" #include "gnc-component-manager.h" #include "gnc-engine-util.h" @@ -263,6 +264,8 @@ gnc_ui_qif_import_druid_make(void) { get_named_page(retval, "load_file_page")); } + gnc_druid_set_colors (GNOME_DRUID (retval->druid)); + gtk_widget_show_all(retval->window); gdk_window_raise (retval->window->window); @@ -1569,6 +1572,8 @@ gnc_ui_qif_import_commodity_prepare_cb(GnomeDruidPage * page, stocks = gh_cdr(stocks); gtk_widget_show_all(new_page->page); } + + gnc_druid_set_colors (GNOME_DRUID (wind->druid)); } static QIFDruidPage * diff --git a/src/gnome/druid-utils.c b/src/gnome/druid-utils.c index e630796420..e9f0acb729 100644 --- a/src/gnome/druid-utils.c +++ b/src/gnome/druid-utils.c @@ -1,6 +1,7 @@ /********************************************************************\ * druid-utils.c -- utility functions for creating druids * * Copyright (C) 2001 Jeremy Collins * + * Copyright (C) 2001 Dave Peticolas * * * * This program is free software; you can redistribute it and/or * * modify it under the terms of the GNU General Public License as * @@ -23,18 +24,10 @@ #include "config.h" -#include "EuroUtils.h" -#include "Group.h" -#include "account-tree.h" #include "dialog-utils.h" #include "druid-utils.h" -#include "global-options.h" -#include "gnc-commodity.h" -#include "gnc-dir.h" #include "gnc-engine-util.h" -#include "gnc-ui-util.h" -#include "gnc-ui.h" -#include "messages.h" + /* This static indicates the debugging module that this .o belongs to. */ static short module = MOD_GUI; @@ -100,3 +93,59 @@ gnc_druid_set_title_image (GnomeDruid *druid, char *image_path) pages = g_list_next(pages); } } + +void +gnc_druid_set_colors (GnomeDruid *druid) +{ + GList *pages; + GdkColor color; + GdkColormap *cm; + + if (!druid) return; + if (!GNOME_IS_DRUID (druid)) return; + + color.red = (gushort) (.60 * 65535); + color.green = (gushort) (.75 * 65535); + color.blue = (gushort) (.60 * 65535); + + cm = gtk_widget_get_colormap (GTK_WIDGET (druid)); + + gdk_colormap_alloc_color(cm, &color, FALSE, TRUE); + + pages = GNOME_DRUID(druid)->children; + + while (pages != NULL) + { + GnomeDruidPage *page = GNOME_DRUID_PAGE (pages->data); + + if (GNOME_IS_DRUID_PAGE_START (page)) + { + GnomeDruidPageStart *page_start; + + page_start = GNOME_DRUID_PAGE_START (page); + + gnome_druid_page_start_set_bg_color (page_start, &color); + gnome_druid_page_start_set_logo_bg_color (page_start, &color); + } + else if (GNOME_IS_DRUID_PAGE_STANDARD (page)) + { + GnomeDruidPageStandard *page_standard; + + page_standard = GNOME_DRUID_PAGE_STANDARD (page); + + gnome_druid_page_standard_set_bg_color (page_standard, &color); + gnome_druid_page_standard_set_logo_bg_color (page_standard, &color); + } + else if (GNOME_IS_DRUID_PAGE_FINISH (page)) + { + GnomeDruidPageFinish *page_finish; + + page_finish = GNOME_DRUID_PAGE_FINISH (page); + + gnome_druid_page_finish_set_bg_color (page_finish, &color); + gnome_druid_page_finish_set_logo_bg_color (page_finish, &color); + } + + pages = g_list_next (pages); + } +} diff --git a/src/gnome/druid-utils.h b/src/gnome/druid-utils.h index f4a16d6eac..872be1d585 100644 --- a/src/gnome/druid-utils.h +++ b/src/gnome/druid-utils.h @@ -29,4 +29,6 @@ void gnc_druid_set_title_image (GnomeDruid *druid, char *image_path); void gnc_druid_set_watermark_image (GnomeDruid *druid, char *image_path); +void gnc_druid_set_colors (GnomeDruid *druid); + #endif diff --git a/src/gnome/new-user-funs.c b/src/gnome/new-user-funs.c index f83d0c73cc..03a793e3c7 100644 --- a/src/gnome/new-user-funs.c +++ b/src/gnome/new-user-funs.c @@ -27,6 +27,7 @@ #include #include "druid-qif-import.h" +#include "druid-utils.h" #include "new-user-callbacks.h" #include "new-user-interface.h" #include "new-user-funs.h" @@ -308,11 +309,15 @@ gnc_create_newUserDialog (void) { GtkWidget *balance_edit; GtkWidget *dialog; + GtkWidget *druid; GtkWidget *box; GHashTable *hash; dialog = create_newUserDialog(); + druid = lookup_widget (dialog, "newUserDruid"); + gnc_druid_set_colors (GNOME_DRUID (druid)); + balance_edit = gnc_amount_edit_new (); gnc_amount_edit_set_evaluate_on_enter (GNC_AMOUNT_EDIT (balance_edit), TRUE); gtk_widget_show (balance_edit); diff --git a/src/gnome/new-user-interface.c b/src/gnome/new-user-interface.c index fd6b64f885..925ef2fdba 100644 --- a/src/gnome/new-user-interface.c +++ b/src/gnome/new-user-interface.c @@ -21,7 +21,7 @@ GtkWidget* create_newUserDialog (void) { GtkWidget *newUserDialog; - GtkWidget *accountChooseDruidPage; + GtkWidget *newUserDruid; GtkWidget *newUserStartPage; GdkColor newUserStartPage_bg_color = { 0, 6425, 6425, 28784 }; GdkColor newUserStartPage_textbox_color = { 0, 65535, 65535, 65535 }; @@ -87,13 +87,13 @@ create_newUserDialog (void) gtk_window_set_position (GTK_WINDOW (newUserDialog), GTK_WIN_POS_MOUSE); gtk_window_set_default_size (GTK_WINDOW (newUserDialog), 640, 480); - accountChooseDruidPage = gnome_druid_new (); - gtk_widget_set_name (accountChooseDruidPage, "accountChooseDruidPage"); - gtk_widget_ref (accountChooseDruidPage); - gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "accountChooseDruidPage", accountChooseDruidPage, + newUserDruid = gnome_druid_new (); + gtk_widget_set_name (newUserDruid, "newUserDruid"); + gtk_widget_ref (newUserDruid); + gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "newUserDruid", newUserDruid, (GtkDestroyNotify) gtk_widget_unref); - gtk_widget_show (accountChooseDruidPage); - gtk_container_add (GTK_CONTAINER (newUserDialog), accountChooseDruidPage); + gtk_widget_show (newUserDruid); + gtk_container_add (GTK_CONTAINER (newUserDialog), newUserDruid); newUserStartPage = gnome_druid_page_start_new (); gtk_widget_set_name (newUserStartPage, "newUserStartPage"); @@ -101,8 +101,8 @@ create_newUserDialog (void) gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "newUserStartPage", newUserStartPage, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (newUserStartPage); - gnome_druid_append_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (newUserStartPage)); - gnome_druid_set_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (newUserStartPage)); + gnome_druid_append_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (newUserStartPage)); + gnome_druid_set_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (newUserStartPage)); gnome_druid_page_start_set_bg_color (GNOME_DRUID_PAGE_START (newUserStartPage), &newUserStartPage_bg_color); gnome_druid_page_start_set_textbox_color (GNOME_DRUID_PAGE_START (newUserStartPage), &newUserStartPage_textbox_color); gnome_druid_page_start_set_logo_bg_color (GNOME_DRUID_PAGE_START (newUserStartPage), &newUserStartPage_logo_bg_color); @@ -116,7 +116,7 @@ create_newUserDialog (void) gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "newAccountCurrencyChoosePage", newAccountCurrencyChoosePage, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show_all (newAccountCurrencyChoosePage); - gnome_druid_append_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (newAccountCurrencyChoosePage)); + gnome_druid_append_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (newAccountCurrencyChoosePage)); gnome_druid_page_standard_set_bg_color (GNOME_DRUID_PAGE_STANDARD (newAccountCurrencyChoosePage), &newAccountCurrencyChoosePage_bg_color); gnome_druid_page_standard_set_logo_bg_color (GNOME_DRUID_PAGE_STANDARD (newAccountCurrencyChoosePage), &newAccountCurrencyChoosePage_logo_bg_color); gnome_druid_page_standard_set_title_color (GNOME_DRUID_PAGE_STANDARD (newAccountCurrencyChoosePage), &newAccountCurrencyChoosePage_title_color); @@ -152,7 +152,7 @@ create_newUserDialog (void) gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "chooseAccountTypesPage", chooseAccountTypesPage, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show_all (chooseAccountTypesPage); - gnome_druid_append_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (chooseAccountTypesPage)); + gnome_druid_append_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (chooseAccountTypesPage)); gnome_druid_page_standard_set_bg_color (GNOME_DRUID_PAGE_STANDARD (chooseAccountTypesPage), &chooseAccountTypesPage_bg_color); gnome_druid_page_standard_set_logo_bg_color (GNOME_DRUID_PAGE_STANDARD (chooseAccountTypesPage), &chooseAccountTypesPage_logo_bg_color); gnome_druid_page_standard_set_title_color (GNOME_DRUID_PAGE_STANDARD (chooseAccountTypesPage), &chooseAccountTypesPage_title_color); @@ -333,7 +333,7 @@ create_newUserDialog (void) gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "finalAccountDruidPage", finalAccountDruidPage, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show_all (finalAccountDruidPage); - gnome_druid_append_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (finalAccountDruidPage)); + gnome_druid_append_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (finalAccountDruidPage)); gnome_druid_page_standard_set_bg_color (GNOME_DRUID_PAGE_STANDARD (finalAccountDruidPage), &finalAccountDruidPage_bg_color); gnome_druid_page_standard_set_logo_bg_color (GNOME_DRUID_PAGE_STANDARD (finalAccountDruidPage), &finalAccountDruidPage_logo_bg_color); gnome_druid_page_standard_set_title_color (GNOME_DRUID_PAGE_STANDARD (finalAccountDruidPage), &finalAccountDruidPage_title_color); @@ -441,15 +441,15 @@ create_newUserDialog (void) gtk_object_set_data_full (GTK_OBJECT (newUserDialog), "newUserDruidFinishPage", newUserDruidFinishPage, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (newUserDruidFinishPage); - gnome_druid_append_page (GNOME_DRUID (accountChooseDruidPage), GNOME_DRUID_PAGE (newUserDruidFinishPage)); + gnome_druid_append_page (GNOME_DRUID (newUserDruid), GNOME_DRUID_PAGE (newUserDruidFinishPage)); gnome_druid_page_finish_set_bg_color (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), &newUserDruidFinishPage_bg_color); gnome_druid_page_finish_set_textbox_color (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), &newUserDruidFinishPage_textbox_color); gnome_druid_page_finish_set_logo_bg_color (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), &newUserDruidFinishPage_logo_bg_color); gnome_druid_page_finish_set_title_color (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), &newUserDruidFinishPage_title_color); gnome_druid_page_finish_set_title (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), _("Finish Account Setup")); - gnome_druid_page_finish_set_text (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), _("If everything is OK, press `Finish' and GnuCash will create\nyour new account hierarchy. Press `Back' to review your selections.\nPress `Cancel' to close this dialog without creating any new accounts.")); + gnome_druid_page_finish_set_text (GNOME_DRUID_PAGE_FINISH (newUserDruidFinishPage), _("Press `Finish' to create your new account hierarchy.\n\nPress `Back' to review your selections.\n\nPress `Cancel' to close this dialog without creating any new accounts.")); - gtk_signal_connect (GTK_OBJECT (accountChooseDruidPage), "cancel", + gtk_signal_connect (GTK_OBJECT (newUserDruid), "cancel", GTK_SIGNAL_FUNC (on_accountChooseDruidPage_cancel), NULL); gtk_signal_connect (GTK_OBJECT (newUserStartPage), "next", diff --git a/src/gnome/new-user.glade b/src/gnome/new-user.glade index aea7293fa8..1e11cfddfb 100644 --- a/src/gnome/new-user.glade +++ b/src/gnome/new-user.glade @@ -39,7 +39,7 @@ GnomeDruid - accountChooseDruidPage + newUserDruid cancel on_accountChooseDruidPage_cancel @@ -582,8 +582,10 @@ accounts may have an opening balance. Tue, 09 Jan 2001 18:08:04 GMT Finish Account Setup - If everything is OK, press `Finish' and GnuCash will create -your new account hierarchy. Press `Back' to review your selections. + Press `Finish' to create your new account hierarchy. + +Press `Back' to review your selections. + Press `Cancel' to close this dialog without creating any new accounts. 25,25,112 255,255,255