Commit Graph

14995 Commits

Author SHA1 Message Date
Geert Janssens
ad1b94bc24 Drop goffice dependency from our html engine
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22799 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-21 16:51:20 +00:00
Geert Janssens
eb5e7aa175 Improve linechart
- convert chart to jqplot
- drop goffice based code

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22798 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-21 11:27:56 +00:00
Phil Longstaff
190665ac2f Initial changes to budget view.
1) Splits gnc-budget-view.c/.h out from gnc-plugin-page-budget.c.  gnc-plugin-page-budget.c now creates a GncBudgetView and provides the overall UI and integration for it.
2) GncBudgetView changes:
    a) If an account has children but does not have a specific budget value for a period, the sum of the children's budget values will be displayed in gray
    b) Totals column on the right provides total for a budget row (account)
    c) At the bottom, totals lines with total income, total expenses, total transfers (assets+liabilities) and grand total (income - expenses - transfers)



git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22796 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-21 01:10:21 +00:00
Geert Janssens
f15df6795c Improve scatterplot chart
- drop goffice based chart, only keep jquery one
- support all jqplot shapes for the markers

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22795 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:52:15 +00:00
Geert Janssens
3c0ce65cec Improve piechart
- drop goffice based chart, only keep jquery one
- move legend outside of plotting area

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22794 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:51:53 +00:00
Geert Janssens
5ffd94062b Improve jqplot's barchart renderer's barWidth and barPadding calculation
The improved formula scales more gracefully from extremely small to
extremely large.

Note: this modifies jqplot itself. We may need to either
- attempt to get this in the upstream code
- see if we can get a similar result by improving our own code

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22793 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:51:41 +00:00
Geert Janssens
1672f14878 Define EOL style for javascript files
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22792 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:51:26 +00:00
Geert Janssens
9d535f045c Improve barchart
- drop goffice based chart, only keep jquery one
- move legend outside of plotting area

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22791 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:51:04 +00:00
Geert Janssens
e5d298e4b5 Update to jqplot 1.0.6
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22790 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:50:43 +00:00
Geert Janssens
f8dabf5db3 jqplot: fix paths to js and css files
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22789 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:50:30 +00:00
Geert Janssens
6776fc0ae8 Fix code to find html files
- look in pkg_data_dir as last resort (eg /usr/share/gnucash)
- effectively test all directories instead of only the second one
- add a debug print line

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22788 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:50:21 +00:00
Geert Janssens
9d5daf7dea Enable jqplot for barchart, piechart and scatterchart
Patch by Andy Clayton

This doesn't work anymore due to changes in other parts of GnuCash, but
is a good starting point to fix it.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22787 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-20 18:50:10 +00:00
Christian Stimming
df6c89eae3 Aqbanking online transfer: Disable the non-SEPA verification rules for SEPA transactions.
Eventually, the SEPA rules need to be implemented, but for now we
just allow any alphanumerics.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22786 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-19 21:05:14 +00:00
Christian Stimming
ac23fa1183 Aqbanking online transfer: Set the date in the gnucash txn dialog to non-sensitive.
Users regularly expect that date to be the online job execution date,
but that's not what is implemented. So we prevent editing here at all.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22784 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-18 20:48:28 +00:00
Christian Stimming
37c66aea36 Minor update for SEPA (European) online transfers (after r22445)
Add direct debit. Make menu items sensitive correctly.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22783 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-18 20:37:08 +00:00
J. Alex Aycinena
81cadea035 Update taxtxf.scm to fix beginning balance sign and signs for Transfer From/To amounts for
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22780 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-16 22:50:01 +00:00
John Ralls
b5042466a9 Fix gnc-cdate format to match that of POSIX cdate
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22776 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-12 23:09:54 +00:00
Christian Stimming
6b0ade1851 Get cutecash/C++ to compile again.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22767 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-08 20:47:42 +00:00
Mike Evans
679d59e445 Bug 683881 Partial implementation.
TODO:
  Saving search preferences doesn't save reverse sort.
  The blank_split remains at the bottom of the register when reverse
  sorted.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22766 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-08 11:02:55 +00:00
Mike Alexander
9ba6e69d5e Avoid a crash when entering invalid dates (e.g., enter "111" for a transaction date).
gnc_parse_date is ignoring the return code from qof_scan_date which causes it to
send uninitialized values to gnc_mktime which crashes if the date is too ridiculous.
Presumably this worked before because mktime took anything without crashing.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22755 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-06 04:24:38 +00:00
J. Alex Aycinena
c295ef3d28 Update txf.scm to reflect changes to US Income Tax Forms and Schedules for 2012.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22753 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-05 00:35:40 +00:00
Mike Alexander
9133c9cfe3 Use gnc-commodity-equiv to compare commodites, not equal?
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22752 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-04 03:15:44 +00:00
Mike Alexander
e4dced2d99 Allow the price quotes perl script to return multiple quotes on a single call.
This makes it easier to add historical prices using a different perl script.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22751 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-04 02:32:50 +00:00
Mike Alexander
8e67373b03 Improve HTML account table generator
Make it possible to add to an existing row and do a better job of
keeping track of whether any values were display for child accounts.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22750 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-02-04 00:50:13 +00:00
Mike Alexander
5c5b6ed77c Do a better job of calculating debit and credit fractions.
Make gnc_split_register_set_cell_fractions agree with
gnc_split_register_get_debcred_entry.
If the account for a split changes recalculate the fractions.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22736 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-30 05:22:46 +00:00
Mike Alexander
31d6c41f5e Do a better job of prompting for an exchange rate only when needed.
If the debit or credit value of a split changes, prompt for an exchange rate.
Don't prompt for an exchange rate in a register that doesn't have a rate cell
(and fix a bug so that it knows that portfolio registers don't have one).
If the transaction has been autofilled and edited start with a nearby rate
from the prices DB.  If it is an existing transaction start with the exchange
rate it already has.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22735 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-30 05:22:38 +00:00
Mike Alexander
e48fb17a13 Don't store a negative reconcile interval.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22723 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-22 22:25:31 +00:00
Geert Janssens
bf34e32303 Bug #680086 - Each Tip of the Day has an n shown at the end
BP

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22721 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-22 10:14:51 +00:00
Geert Janssens
bc0940a49e Win32 build: add attribution for a code snippet in bootstrap
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22720 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-22 10:14:35 +00:00
J. Alex Aycinena
ced147f641 Remove circular dependency introduced in r22681
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22717 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 23:29:35 +00:00
Geert Janssens
141efcbedc Fix another eol issue
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22716 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 21:00:51 +00:00
Geert Janssens
c33eaf006e Win32 build: some more patchfile cleanups
Wrap patching code in conditional in most cases to only run patch if
there actually is a patch file available.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22715 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 18:28:00 +00:00
Geert Janssens
15c3a1bfd4 Win32 build: rename patch files to consistently end in .patch
This way they will be checked in/out in proper line ending style on all
supported platforms.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22714 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 18:27:51 +00:00
Geert Janssens
08cbbca194 Win32 build: remove obsolete patches
The code used to apply the patches if present still remains to cater for
possible future patches.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22713 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 18:27:40 +00:00
Geert Janssens
98bf2ad608 Define line ending style for different file types
Additionally, fix line endings on some files that were inconsistent
in this regard.

This gives a more consistent experience on all development
platforms.

All source files (be it scripts, makefiles, autoconf/automake
files,...) are given an explicit line ending style. For most
LF was chosen. Exceptions are typical windows scripts (.bat, .cmd,
.vbs,...) and some files related to the windows installer. Those
are fixed at CTRL/LF because the installer would have issues
otherwise).
The remainder of files are mostly plain text files (README's,
CHANGELOG's,...). These files are stored with LF line ending
in the repo, but checked out with the platform's native
line ending style. git takes proper care of the necessary
conversions automatically.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22712 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 18:27:27 +00:00
Geert Janssens
f6e626276b Bug #604520 Explain scope of find transaction tool.
Signed-off-by: Yawar Amin <yawar.amin@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22711 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-19 09:25:27 +00:00
Geert Janssens
5f28fc8c88 Win32 build system: Experimental bootstrap script
The goal of this script is to make is extremely easy to start gnucash
development on Windows. After downloading and running this script, the
user should be ready to start coding.

Note that this is not the case yet. The bootstrap script is only the
first step in that direction.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22707 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-18 16:02:09 +00:00
Geert Janssens
f3a35cc6a1 Bug #672364 - does not properly handle XML parse errors, leading to
possible data loss

Handle return value of xmlParseDocument()
Ignoring errors can lead to data loss.
Author: Sébastien Villemot <sebastien@debian.org>
Bug-Debian: http://bugs.debian.org/696282
BP

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22703 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-15 16:15:57 +00:00
John Ralls
2824afbabc Fix #638955
Connect the `Help' button in the `Close Book' dialog box (Tools > Close
Book) to newly-written help section on book closing.

Signed-off-by: Yawar Amin <yawar.amin@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22701 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-14 01:18:48 +00:00
John Ralls
19c65666d9 Fix string leak in gnc_gnome_help()
Thanks to Yawar Amin for pointing it out.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22698 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-13 22:51:44 +00:00
Mike Alexander
18bb5e843d Fix gnc_difftime so it is the same as difftime, which it replaces.
It was computing the negative of the expected value.  The most obvious
effect of this was that the reconcile interval became negative when you
reconciled an account so each reconciliation was earlier than the previous.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22688 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-01-01 00:10:07 +00:00
Geert Janssens
365237aec4 Move gnc_guile_strip_comments to core-utils and normalize its name to
gnc_scm_strip_comments

Also make it a true convenience functions by doing the conversion from
an scm string to a c string internally. This saves the caller a manual
conversion step.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22687 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:21:03 +00:00
Geert Janssens
feb2eac9e4 Normalize naming convention for guile convenience functions
Let them all start with gnc_scm_*
Copy the guile naming convention as close as possible for the remainder

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22686 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:20:53 +00:00
Geert Janssens
5666e5bd6d Properly use scm_dynwind_* functions where they still make sense
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22685 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:20:39 +00:00
Geert Janssens
06eb020f7f Readd gnc_scm_to_locale_string function and use it where appropriate
This function is a wrapper around scm_to_locale_string which returns
a gchar * to be freed with g_free. The return value of the original
function has to be freed with free. This is confusing since most of
the gnucash code relies on g_malloc/g_free.

While at it, clean up a lot of memory handling issues around (gnc_)scm_to_locale_string

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22684 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:20:29 +00:00
Geert Janssens
bc42791f92 Use gnc_guile_call1_to_string convenience function where appropriate
And improve memory handling surrounding it where needed.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22683 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:20:17 +00:00
Geert Janssens
6fb7a4f7a2 Move some guile convenience routines to core utils
They don't depend on any gui or engine code and are
used throughout the source

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22682 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 18:20:05 +00:00
J. Alex Aycinena
7cdd7372f5 Implement a Book Option to give users the choice to use the transaction number field (default and current behaviour) or, alternatively, the split action field of the anchor split for 'Num' column on registers, reports, import and export, where applicable. The difference between the two is that with the default, the same 'Num' is displayed for a given transaction regardless of what register it is viewed in and with the new option, a different 'Num' can be entered/displayed for a given transaction in each register it is viewed in. In both cases, the 'next number logic' of the 'Num' cell is based on the account of the register the transaction is entered/viewed from but in one case it fills the transaction number, in the other, it fills the split action field of the anchor split (with the transaction number field displayed in the register cell labeled 'T-Num'). In both cases, both fields are visible and can be used as free-form text in double-line mode for any value the user wants. If the new option is not selected, there should be no change in Gnucash's behaviour with the exception of displaying the book options dialog in 'new book' situations.
The changes made are:

1.  Implement the new book option to select source for 'num' cell:
     libqof/qof/qofbookslots.h - define num source option
     engine/engine.i - define 'NUM-FIELD-SOURCE' as an option name and
         'SPLIT-ACTION' as a term for sorting queries
     app-utils/business-prefs.scm - define book option for num-field-source
     app-utils/app-utils.scm - define and export book option for num-field-source

2.  Implement functions to get book option setting and to test:
     libqof/qof/qofbook.c & .h - define function to get number source book option
     libqof/qof/test/test-qofbook.c - test function to get number source book option

3.  Implement a notification mechanism for book option changes:
     engine/engine-helpers.c & .h - define functions to register callbacks,
         define function to remove callbacks and
         define function to initiate callbacks on book num-source option changes
     core-utils/gnc-features.c & .h - define feature for num-source
     app-utils/gnc-ui-util.c & .h - define gnc_book_option_num_field_source_change_cb;
         include setting of feature flag on initial use
     gnome-utils/gnc-main-window.c - change name of gnc_options_dialog_apply_cb
         function to gnc_book_options_dialog_apply_cb and adjust function to 
         call function gnc_book_option_num_field_source_change_cb when book
         option for num-field-source changes; change name of
         gnc_options_dialog_close_cb to gnc_book_options_dialog_close_cb

4.  Implement 'help' button response on Book Option Dialog:
     gnome-utils/gnc-ui.h - define "book-options" section of help manual
     gnome-utils/gnc-gnome-utils.c & .h - implement Book Options help callback
     gnome-utils/gnc-main-window.c - use gnc_options_dialog_set_book_options_help_cb
         to make help button active

5.  Implement utility functions to get/set number/action based on book option:
     engine/engine-helpers.c & .h - define 'gnc_get_num_action' function
         define 'gnc_get_action_num' function
         define 'gnc_set_num_action' function
     engine/engine.i - make get/set num/action functions available to guile &
         allow #f to be used in place of NULL from guile
     engine/Transaction.h - add reference to utility functions in comments to 
         xaccTransSetNum and xaccTransGetNum functions
     engine/Split.h -  add reference to utility functions in comments to 
         xaccSplitSetAction and xaccSplitGetAction functions

6.  Implement register use of num source book option; for General, Income and Search
    Ledgers, since there is no anchor split, always show tran-num in transaction
    cursor, but vary label to correspond to book option:
     register/ledger-core/split-register.h - define TNUM_CELL
         define CURSOR_DOUBLE_LEDGER_NUM_ACTN cursor name to use TNUM_CELL
         define CURSOR_DOUBLE_JOURNAL_NUM_ACTN cursor name to use TNUM_CELL
         add boolean to split_reg structure to hold num source book option
     register/ledger-core/split-register-layout.c -
         add logic to define and set up new ledger/journal cursors with TNUM_CELLs
         add logic to add the new cursors to a layout
         add logic to add TNUM_CELL to a layout
     register/ledger-core/split-register-model.c -
         define function to get TNUM_CELL label
         add logic to recognize ledger/journal cursors with TNUM_CELL
         modify function to get NUM_CELL value based on book option and register
             type
         define function to get TNUM_CELL value
         adjust num help text to reflect book option choice
         define function to get TNUM_CELL help
         modify function to get action help to reflect book option choice
         set up handlers for TNUM_CELL
     register/ledger-core/split-register-model-save.c -
         use 'gnc_set_num_action' function to set num/action for NUM_CELL based
             on book option
         define function to save TNUM_CELL using 'gnc_set_num_action' function
         set save handler for TNUM_CELL
     register/ledger-core/split-register-util.c - 
         modify logic to recognize ledger/journal cursors with tnum_cell
     register/ledger-core/split-register.c -
         define split_register_book_option_changed function
         register split_register_book_option_changed function in register init
         initialize register structure setting to book option
         remove split_register_book_option_changed function in register destroy
         modify gnc_split_register_save_to_scm to handle TNUM_CELL

7.  Enhance transaction copy/duplicate logic to accommodate new book option:
     gnome/gtkbuilder/gnc-plugin-page-register.glade -
         add widgets to handle trans number and/or split action based on book option
     gnome-utils/dialog-dup-trans.c & .h -
         add capability to display and handle 'Num' field according to book option
     gnome/gnc-plugin-page-register.c - define gnc_find_register_by_account
     register/ledger-core/split-register.c -
         modify gnc_split_register_duplicate_current to accomodate book option
         setting
     register/ledger-core/Makefile.am - add GNOME_CFLAGS
     register/ledger-core/test/Makefile.am - add libgnc-gnome.la

8.  Adjust register sort and sort labels related to Num/Action radio buttons to
    correspond to book option for clarity:
     gnome/gnc-plugin-page-register.c -
         define gnc_plugin_page_register_sort_book_option_changed to adjust labels
         register function in gnc_plugin_page_register_cmd_view_sort_by
             and save num and action radio widgets
         initialize radio widget labels to correspond to book option
         remove function in gnc_plugin_page_register_sort_response_cb
             and clear num and action radio widgets
     gnome/gnc-split-reg.c & h. - 
         create versions of gnc_split_reg_sort and gnc_split_reg_set_sort to force
             a re-sort to be used when num-source book option changes
     engine/Transaction.c & .h -
         modify default sort to use split action in place of tran num per book
             option if called from xaccSplitOrder
     engine/Split.c - 
         modify xaccSplitOrder to call xaccTransOrder_num_action to switch use of
             split action and tran num per book option
     engine/test/utest-Split.c -
         modify test_xaccSplitOrder to call xaccTransOrder_num_action based on
             book option

9.  Adjust transaction find labels related to Num/Action to correspond to book option
    for clarity:
     gnome/dialog-find-transactions.c - adjust labels in search criteria based
         on book option
     gnome-search/dialog-search.c -
         define gnc_search_dialog_book_option_changed to adjust labels
         register function in gnc_search_dialog_init_widgets when searching
             for splits
         remove function in gnc_search_dialog_close_cb if registered

10. Modify new file process to allow setting of num-source (actually, all) book
    option(s) during New Account Hierarchy Setup:
     gnome-utils/gtkbuilder/dialog-preferences.glade - add a user preference for
         the default setting for 'num-source' for new books
     core-utils/gnc-gconf-utils.h - define KEY_NUM_SOURCE
     gnome-utils/gnc-gnome-utils.c & h. -
         define gnc_options_dialog_set_new_book_option_values to retrieve
         preference values
     gnome-utils/dialog-options.c & .h - define gnc_options_dialog_new_modal to
         surpress apply button
     gnome-utils/gnc-main-window.c - define function gnc_book_options_dialog_cb
         with arguments so that the window can be called in modal mode and the
         title changed and return dialog widget; call gnc_options_dialog_new_modal
         instead of gnc_options_dialog_new; call this function from
         gnc_main_window_cmd_file_properties with new arguments; for modal mode,
         call gnc-options-dialog-set-new-book-option-values to initialize values
         from preferences
     app-utils/gnc-ui-util.c & h. - create function gnc_is_new_book for
         determining when a new book is being created
     gnome-utils/dialog-utils.c & h. - define gnc_new_book_option_display to
         display book options dialog in modal mode
     gnome/gtkbuilder/assistant-hierarchy.glade - add notification about book
         options to currency page
     gnome/assistant-hierarchy.c - add ability to set book option initialized
         from preferences value for new books by using functions gnc_is_new_book
         and gnc_new_book_option_display

11. Modify Import QIF process to recognize a new-book situation and allow setting
    of book options during first import into a new book; also follow book option
    setting for num source in importing number whether new book or not:
     import-export/qif-import/assistant-qif-import.glade - add notification about
         book options to currency page
     import-export/qif-import/assistant-qif-import.c - using function
         gnc_is_new_book to identify 'new book' situation and set flag; add
         logic to handle 'new-book' situation by calling
         gnc_new_book_option_display function
     import-export/qif-import/qif-to-gnc.scm - use 'gnc_set_num_action' function
         to import number to correct field based on book option

12. Modify Import OFX/QFX process to recognize a new-book situation and allow setting
    of book options during first import into a new book; also follow book option
    setting for num source in importing number whether new book or not:
     import-export/ofx/gnc-ofx-import.c - use 'gnc_set_num_action' function to import
         number based on book option; identify 'new book' situation using function
         gnc_is_new_book and set flag; add logic to handle 'new-book' situation
         by raising book options dialog by calling gnc_new_book_option_display
         function
     import-export/import-backend.c - use 'gnc_get_num_action' function to 
         retrieve number from transactions to be matched based on book option

13. Modify Import AqBanking process to recognize a new-book situation and allow
    setting of book options during first import into a new book; also follow
    book option setting for num source in importing number:
     import-export/aqbanking/gnc-file-aqb-import.c - identify 'new book'
         situation using function gnc_is_new_book and handle by raising book
         options dialog by calling gnc_new_book_option_display function
     import-export/aqbanking/gnc-ab-utils.c - use 'gnc_set_num_action' function
         to set number based on book option

14. Modify Import Transactions from CSV process to recognize a new-book situation
    and allow setting of book options during first import into a new book; also
    follow book option setting for num source in importing number whether new
    book or not:
     import-export/csv-import/assistant-csv-trans-import.glade - modify
         commments to alert user of raising book options dialog in cases of csv
         import into a new book
     import-export/csv-import/gnc-csv-model.c & h. - use 'gnc_set_num_action'
         function to import number based on book option
     import-export/csv-import/assistant-csv-trans-import.c - add logic to handle
         'new-book' situation by raising book options dialog by calling
         gnc_new_book_option_display function; identify 'new book' situation
         using function gnc_is_new_book and set flag

15. Modify Import Accounts from CSV process to recognize a new-book situation
    and allow setting of book options during first import into a new book
     import-export/csv-import/assistant-csv-account-import.c & .h - add logic to
         handle 'new-book' situation by raising book options dialog by calling
         gnc_new_book_option_display function; identify 'new book' situation
         using function gnc_is_new_book and set flag

16. Modify Export Transactions to CSV process to follow book option setting
    for num source in exporting transactions:
     import-export/csv-export/csv-transactions-export.c - modify headings to
         reflect num-source book option and use 'gnc_get_num_action' function
         to retrieve number and action

17. Modify register reporting to reflect book option setting for num source:
     gnome/gnc-plugin-page-register.c - determine and pass along ledger-type?
         argument to gnc:register-report-create function
     gnome/gnc-plugin-page-register2.c - determine and pass along ledger-type?
         argument to gnc:register-report-create function
     report/standard-reports/standard-reports.scm - add ledger-type? argument
         to gnc:register-report-create function; pass it along to
         gnc:register-report-create-internal function
     report/standard-reports/register.scm - add ledger-type? argument to
         gnc:register-report-create-internal function; use 'gnc-get-num-action'
         function in place of xaccTransGetNum and 'gnc-get-action-num' function
         in place of xaccSplitGetAction and modify report headings and option
         text accordingly

18. Modify all places that use xaccTransSetNum and/or xaccSplitSetAction to use
    'gnc_set_num_action' function to set number based on book option except
    engine/Transaction.c & .h, engine/test-core/test-engine-stuff.c,
    engine/Split.c & .h, engine/test/utest-Split.c, engine/engine-helpers.c & .h,
    engine/engine-interface.scm, backend/xml/gnc-transaction-xml-v2.c,
    backend/xml/io-gncxml-v1.c, import-export/log-replay/gnc-log-replay.c:
     engine/gncOwner.c - use 'gnc_set_num_action' function to set number based
         on book option
     engine/gncInvoice.c - use 'gnc_set_num_action' function to set number based
         on book option
     engine/SchedXaction.c - use 'gnc_set_num_action' function to set number and
         action
     engine/cap-gains.c - use 'gnc_set_num_action' function to set split-action
     gnome-utils/dialog-transfer.c - use 'gnc_set_num_action' function to set
         number based on book option
     gnome-utils/gnc-tree-view-split-reg.c - use 'gnc_set_num_action' function
         to set number/action based on book option
     gnome/assistant-stock-split.c - use 'gnc_set_num_action' function to set
         split-action

19. Modify all places that use xaccTransGetNum and/or xaccSplitGetAction to use
    'gnc_get_num_action' or 'gnc_get_action_num' functions to get number based
    on book option except engine/Transaction.c & .h,
    engine/test-core/test-engine-stuff.c, engine/Split.c & h.,
    engine/test/utest-Split.c, engine/engine-helpers.c,
    engine/engine-interface.scm, backend/xml/gnc-transaction-xml-v2.c,
    backend/xml/test/test-xml-transaction.c:
     gnome/dialog-lot-viewer.c - use 'gnc_get_num_action' function to retrieve
         number based on book option
     gnome/dialog-sx-from-trans.c - use 'gnc_get_num_action' function to
         retrieve number and action
     gnome/dialog-print-check.c - use 'gnc_get_num_action' function to
         retrieve number and 'gnc_get_action_num' function to retrieve action
     register/ledger-core/split-register-model.c - use 'gnc_get_num_action'
         function to retrieve number based on book option
     register/ledger-core/split-register-load.c - use 'gnc_get_num_action'
         function to retrieve number based on book option
     register/ledger-core/split-register-control.c - use 'gnc_get_num_action'
         function to retrieve action
     register/ledger-core/split-register.c - use 'gnc_get_num_action'
         function to retrieve transaction-num 
     engine/cap-gains.c - use 'gnc_get_num_action' function to get split-action
     gnome-utils/gnc-tree-view-split-reg.c - use 'gnc_get_num_action' function
         to retrieve number and 'gnc_get_action_num' function to retrieve action
     gnome-utils/gnc-tree-model-split-reg.c - use 'gnc_get_num_action' function
         to retrieve transaction-number but may not be getting what is expected
         if book option to use split-action for 'num' is set
     report/locale-specific/us/taxtxf.scm - use 'gnc-get-num-action' function in
         place of xaccTransGetNum and 'gnc-get-action-num' function in place of 
         xaccSplitGetAction and modify report headings and option text accordingly
     report/standard-reports/transaction.scm - use 'gnc-get-num-action' function
         in place of xaccTransGetNum, adjust sorting based on book option and
         modify report headings and option text accordingly; add 'SPLIT-ACTION'
         as a term for sorting queries
     report/business-reports/customer-summary.scm - use 'gnc-get-num-action'
         function in place of xaccTransGetNum
     report/business-reports/owner-report.scm - use 'gnc-get-num-action'
         function in place of xaccTransGetNum
     report/business-reports/job-report.scm - use 'gnc-get-num-action' function
         in place of xaccTransGetNum
     business/business-gnome/dialog-payment.c - use 'gnc_get_num_action'
         function to retrieve number based on book option


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22681 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-22 06:00:54 +00:00
Geert Janssens
5ff9e099e9 Fix compiler warnings introduced by the guile 2 patches
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22680 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-21 09:19:41 +00:00
Mike Alexander
ba9b85a260 Use the correct fraction when editing expanded multiple currency transactions.
When a transaction is expanded and trading accounts are in use, the debit
and credit cells contain values in the split's commodity not the transaction's
currency.  For example if you have a transaction involving JPY and USD
currencies and the transaction's currency is JPY, you can only enter whole
dollar amounts in the USD splits.  This fixes this problem.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22673 57a11ea4-9604-0410-9ed3-97b8803252fd
2012-12-19 05:34:48 +00:00