Commit Graph

12273 Commits

Author SHA1 Message Date
Christian Stimming
7619232f3b Really fix r18495 (#586122) to look up the so-name of gwenhywfar correctly.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18502 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-15 20:30:15 +00:00
Geert Janssens
51f073af01 Require gtk+ >= 2.8
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18501 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 22:25:35 +00:00
Geert Janssens
e3039a0457 Some usability improvements to the Save As.../Open dialog (part 2)
Forgot to add the changes in c code...

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18500 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 22:24:47 +00:00
Geert Janssens
edaf8bcd27 Some usability improvements to the Save As.../Open dialog
* The dialog gets a proper title
* Only show the File frame or the Database frame,
  as relevant to the chosen data format
* Set a minimum width. Without it the dialog comes up too narrow.
* Some minor layout changes (spacing, justification,...) to harmonize with
  other GnuCash dialogs.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18499 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 21:35:53 +00:00
Mike Alexander
daa1c8e23b Symlink the reports to the build directory to make it easier to use them when
running in place after a build without installing GnuCash.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18498 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 05:52:22 +00:00
Mike Alexander
287c85ce9d Use resolve-interface instead of resolve-module when loading reports fo only the
exported interface gets imported instead of everything defined in the file.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18497 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 05:50:57 +00:00
Mike Alexander
e7cd4d4595 Make the dbi backend tests work correctly if dbd is installed in a nonstandard location.
Supply a GNC_DBD_DIR environment variable to the tests so it knows where to find the 
database modules.  This is needed if libdbi is installed via MacPorts on OS X.



git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18496 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-14 05:48:45 +00:00
Christian Stimming
3f658ca02e Fix #586122 (follow-up to r18488) by using aqbanking/version.h from its installation path.
Also look up the gwenhywfar so-name accordingly.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18495 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-13 21:16:25 +00:00
Phil Longstaff
d8612ea9ac Revert r18426 - "Bug #121695: Support account reparenting through drag and drop"
Causing CRIT messages when you change accounts in a report options dialog.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18494 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-13 19:22:12 +00:00
Phil Longstaff
fce8b781d1 Add flags to help with valgrind on glib
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18493 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-13 19:19:59 +00:00
Phil Longstaff
49a9fb8bc9 Free prices so that they can be deleted when the book is closed
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18492 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-13 19:18:35 +00:00
Phil Longstaff
15491e23e7 Free budgets when closing a book
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18491 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-13 00:42:12 +00:00
Phil Longstaff
66b64e45e8 When closing the book, destroy all lots (found by valgrind)
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18490 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-12 20:05:44 +00:00
Phil Longstaff
75e1094cfd Free memory leaks
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18489 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-12 00:15:50 +00:00
Geert Janssens
c5ada60a9b Bug 586122 - The AqBanking Wizard can't be loaded: plugins\20 folder to be renamed into plugins\16
The patch evaluates and configures the proper paths at build time, retrieving
the required info directly from the aqbanking source

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18488 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-11 19:57:17 +00:00
Christian Stimming
9d6a833973 Updated Dutch translation, by Mark Haanen and Jos, copied from the Translation Project.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18487 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-11 19:41:36 +00:00
Phil Longstaff
e278b0c643 Add qof_backend_module_finalize() routine to call dbi_shutdown() to free allocated resources.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18486 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-11 17:32:35 +00:00
Phil Longstaff
a3b87ece92 Add qof_finalize_backend_libraries() which is called during shutdown. This routine checks each backend
library for an exported qof_backend_module_finalize() routine, and if it exists, calls it so that the
backend can free any resources which have been allocated.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18485 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-11 17:31:35 +00:00
Phil Longstaff
16144d6828 Fix some memory leaks found by valgrinding tests
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18483 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-11 02:28:07 +00:00
John Ralls
21d920d0de Remove erroneous use lib from gnc-fq-*, along with PERLINC setup in configure.in
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18482 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-10 22:39:33 +00:00
Christian Stimming
b0824d6ceb Small UI string corrections related to the recent tax enhancements.
Patch by J. Alex Aycinena.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18479 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-09 21:30:50 +00:00
Christian Stimming
355d8c41fa Small UI string corrections related to the recent tax enhancements.
Patch by J. Alex Aycinena.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18477 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-09 20:56:54 +00:00
Geert Janssens
8bd170e56c Payment dialog layout improvements
- Rearrange the frames so that the Transfer Account frame gets
  more space
- Add tooltips to (owner), (invoice) and amount related widgets.
- Properly align the invoice_label widget

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18474 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-09 15:14:35 +00:00
Christian Stimming
9c6806c353 Decrease verbosity during win32 packaging: Inno, gconftool-2, htmlhelp compiler (hhc) with less output.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18473 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-08 20:42:46 +00:00
Phil Longstaff
8ec302bf40 Disable it_IT help in the win32 binary
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18470 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-06 18:58:17 +00:00
Christian Stimming
116b8b2371 Bug #603186: Fix crash with txf.scm on win32
Patch by J. Alex Aycinena:

In further testing I discovered that I omitted some codes in
txf-de_DE.scm and txf.scm that need to be there. Without them gnucash
crashes under certain circumstances.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18465 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-04 21:09:59 +00:00
Christian Stimming
a699183ae5 Bug #537476: Fix currency trading account preference lookup
Patch by Mike Alexander:

There are a few values related to the trading accounts preference that are
needed in both Scheme and C code.  Since one of them was already defined in
Scheme before I started, I defined all of them there and tried to import them
to C.  This is obviously not a good idea, especially since the make check tests
don't even fire up Guile so Scheme code isn't available.  This patch changes
things around to define the values in C and import them to Scheme.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18464 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-04 20:26:48 +00:00
Christian Stimming
7359e68827 Updated Durch translation by Mark Haanen, copied from Translation Project.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18460 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-03 21:12:42 +00:00
Phil Longstaff
27f66f6ed9 Update revision number to 2.3.8
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18456 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-02 00:41:26 +00:00
Mike Alexander
e150417410 Fix the bug described in comment 19 of bug 537476, balance sheet wrong without trading accounts.
The problems is that xaccQueryAddAccountMatch and xaccQueryAddAccountGUIDMatch
match all accounts rather than no accounts when given a null account list.  This means
that gnc:accountlist-get-comm-balance-at-date returns a balance for all accounts when
given no accounts.  This caused the balance sheet report to fail if there were no trading
accounts.  There is a similar problem with gnc:account-get-trans-type-splits-interval in 
gnc:html-acct-table-add-accounts! in html-acct-table.scm that is also fixed.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18455 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-12-01 05:15:02 +00:00
Phil Longstaff
bf7a7a7497 Recreate index after updating table
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18454 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-30 23:21:50 +00:00
Christian Stimming
12069d5947 Bug #310567: Disable newly introduced "shift txn forward" feature again because it is unfinished.
The behaviour of the menu item is not yet clear: After
clicking on it, nothing changes in the transaction, only after I additionally
pressed "enter". After this, the running balance currently isn't
updated, which is additionally confusing. These two points would need to be
fixed before we can recommend this feature for the next stable version 2.4.0.
I disable it for now so that we can release something.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18450 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-29 20:22:48 +00:00
Phil Longstaff
58f05266fb Temporarily disable currency trading accounts so that 'make check' will pass so that
2.3.8 can be released.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18449 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-29 19:48:21 +00:00
Phil Longstaff
48a3d3cd9a Fix test-resolve-file-path - results have changed now that resolve_file_path uses '_'
instead of ',' for special characters.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18448 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-29 19:47:15 +00:00
Phil Longstaff
4e37dacb60 Fix compilation problem in test - I'm not really sure why this is now a problem. Perhaps
libxml include files have changed between ubuntu 9.04 and 9.10.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18447 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-29 19:45:43 +00:00
Phil Longstaff
763e3ed280 Add src/gnome-utils/gnc-tree-model-account-drag.c to po/POTFILES.in
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18446 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-29 19:43:36 +00:00
Phil Longstaff
5b49c70ed2 Fix bug 600486 - Unable to open sqllite file on Win7 64 bit
Unposted invoice has NULL tx guid, which wasn't being handled correctly.  Doesn't crash
on linux but does on windows.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18444 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-28 15:51:49 +00:00
Phil Longstaff
d0f22524ee Fix Bug 591573 - "File|Save As" with xml option and no file name crashes
With no file name, entered, filename returned from file_chooser is NULL,
which led to the crash.  If NULL is returned, just ignore the button press.

Proper UI would not allow Save As to be clicked unless conditions were right,
but I'm not sure how to make that happen.  There is a signal emitted when a
file is selected, but not when characters are typed into the name text field.



git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18443 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-27 03:13:41 +00:00
Phil Longstaff
a001f55fce Set debug level for gnc.backend.dbi automatically to DEBUG. This will ensure that all SQL statements are
logged into the gnucash.trace file.  This can provide vital information in case of problems.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18441 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-24 00:09:29 +00:00
Phil Longstaff
c30ad8789b Fix bug 602603 - State file cannot be saved with MySQL because of colon in filename
When creating file names for the "books" or "data" directory under ".gnucash", convert
'/' and ':' to '_'.  This may mean state is lost for cases with a full url including
type (since the previous conversion was '/' to ','), but this will only happen once.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18440 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-24 00:07:45 +00:00
Christian Stimming
4cd8d17259 Bug #570895: Allow reporting for single budget periods in budget income statement
Patch by Forest Bond:

The budget income statement would be more useful if it allowed reporting for
single budget periods, rather than always reporting for the entire budget at
once. This patch implements the requested feature.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18439 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-23 19:58:22 +00:00
Christian Stimming
f5babd8853 Bug #602744: Fix broken tip_of_the_day list creation.
Patch in r18417 from bug #602062 was buggy - removing the "-x c" argument.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18438 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-23 19:46:55 +00:00
Christian Stimming
5e12c3188b Fix memory leak: Let the pixbuf renderer for goffice plots be unreferenced upon plot destruction.
Pointed out by Jean Bréfort.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18437 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-22 20:39:53 +00:00
Christian Stimming
9a0b1dd937 Add Latvian translation by Valdis Vitolins <valdis.Vitolins@odo.lv>
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18435 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-22 20:16:23 +00:00
Christian Stimming
b60c9346e1 Add libguile CFLAGS and LIBADD because since r18429, qofbook.c wants to use libguile functions.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18434 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-22 20:11:48 +00:00
Christian Stimming
bf68cf1e5a Fix too-new gtk_dialog_get_content_area function of r18413:
Patch by J. Alex Aycinena:

‘gtk_dialog_get_content_area’ is from GTK version 2.14. The attached
patch uses the prior '(GTK_DIALOG(dialog)->vbox)' in place of
'gtk_dialog_get_content_area (GTK_DIALOG (dialog))' and compiled
successfully on my GTK version 2.16 and the application operated
properly.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18433 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-22 20:05:46 +00:00
Phil Longstaff
7333f1b62a Transaction post date also needs to allow NULL values.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18432 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-21 19:53:00 +00:00
Phil Longstaff
18913c066d Fix bug 591098 - when starting Gnucash, "Present" and all other collumns exept TOTAL are zero until you open the account
Fix bug 598618 -  does not calculate account balances correctly

Both of these are happening because not all transactions are being loaded at startup.  Bug 591098
happens because the account assumes it has all splits loaded, and looks for the first one after the
requested date to get the present balance.  The second happens because then the splits associated
with an invoice transaction are being loaded, the balance cannot be updated properly.

This change reverts back to loading all transactions on startup.  Once gnucash is a proper database
app, we can change back to loading transactions only when needed.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18431 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-21 04:32:26 +00:00
Christian Stimming
812c02be0b Temporary workaround for crash at startup after r18429.
Before this change, gnucash crashes on start-up with Backtrace:
In unknown file:
   ?: 0* gnc:*book-label*

<unnamed port>: In expression gnc:*book-label*:
<unnamed port>: Unbound variable: gnc:*book-label*

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18430 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-20 21:12:21 +00:00
Christian Stimming
b578c56b27 Bug #537476: Implement currency trading accounts optionally, to be enabled per-book.
Patch by Mike Alexander:

This patch implements trading accounts somewhat as described in Peter
Selinger's document at
<http://www.mathstat.dal.ca/~selinger/accounting/gnucash.html>.  Although he
describes it as a multiple currency problem, it really applies to any
transactions involving multiple commodities (for example buying or selling a
stock)  Hence I've called the trading accounts "commodity exchange accounts"
which seems more descriptive.

In summary these patches add an option to use commodity exchange accounts and
if it is on a transaction must be balanced both in value (in the transaction
currency) and in each commodity or currency used in any split in the
transaction.  If a transaction only contains splits in the transaction currency
then this is the same rule as Gnucash has always enforced.

In this patch, the option to use trading accounts has been moved from
Edit->Preferences to File->Properties and is now associated with the active
book instead of being a global option.  If you have set the global value on in
a previous version you will need to set it on again in each file for which you
want trading accounts, the previous global setting will be ignored.

A more detailed list of changes follows:

1.  Added a "Use commodity exchange accounts" per-book option.

2.  Added gnc_monetary and MonetaryList data types.

3.  Renamed xaccTransGetImbalance to xaccTransGetImbalanceValue and added a new
xaccTransGetImbalance that returns a MonetaryList.  Also added
xaccTransIsBalanced to see if the transaction is balanced without returning a
GList that needs to be freed.  It calls both xaccTransGetImbalance and
xaccTransGetImbalanceValue since a transaction may be unbalanced with regard to
either without being unbalanced with regard to the other.

4.  Changed gnc_split_register_get_debcred_bg_color to use xaccTransIsBalanced.

5.  Changed gnc_split_register_balance_trans to not offer to adjust an existing
split if there imbalances in multiple currencies.  Because of bugs in the
register code this is rarely called.

6.  Changed importers to use xaccTransGetImbalanceValue to check for imbalance,
assuming that they won't create multiple currency trasactions.

7.  Changed xaccTransScrubImbalance to create a balancing split for each
imbalanced commodity in the transaction.  Also balances the transaction value.
The commodity balancing splits go into accounts in the hierarchy
Trading:NAMESPACE:COMMODITY.  The value balancing splits go into
Imbalance-CURRENCY as before.

8.  Changed xaccSplitConvertAmount to use xaccTransIsBalanced instead of
xaccTransGetImbalance.

9.  Changed gnc_split_register_get_debcred_entry to sometimes use the split
amount instead of value if using currency accounts.

If the register is a stock register (i.e., shows shares and prices), it uses
the value if the split is in the register commodity (i.e. is for the stock) and
the amount otherwise.  It shows the currency symbol unless the commodity is the
default currency.

If the register is not a stock register it always uses the amount and shows the
currency symbol if the split is not in the register commodity.

Also changed it to not return a value for a null split unless the transaction
is unbalanced in exactly one currency.  This is what goes in a blank split as
the proposed value.

10. Changed refresh_model_row to use xaccTransGetImbalanceValue to get the
imbalance, assuming that importers don't create transactions in multiple
currencies.  Also same change in gnc_import_process_trans_item,
downloaded_transaction_append, and gnc_import_TransInfo_is_balanced.

11. Changed the TRANS_IMBALANCE accessor method in xaccTransRegister to use
xaccTransGetImbalanceValue.  As far as I can tell this is only used by the
"pd-balance" query type in gnc_scm2query_term_query_v1() defined in
engine-helpers.c.  This query type only tests the result for zero/non-zero.

12. Changed xaccTransGetAccountConvRate to accept any split into the correct
commodity instead of insisting on one into the provided account.  Then can use
it in xaccTransScrubImbalance to set the value of the imbalance split from its
amount, however later changed xaccTransScrubImbalance to not use it.  Instead
it sets the value for the new split correctly to keep the value of the whole
transaction balanced.

13. Changed the balance sheet report to include a new option to not compute
unrealized gains and losses.

14. Related to 9 above, changed gnc_split_register_auto_calc to not do anything
if given a stock register where the value cell doesn't contain the value.

15. Also related to 9, changed gnc_split_register_save_amount_values to set the
amount and value fields in the split correctly when using trading accounts.

16. Changed the new account and edit account dialogs to allow any commodity or
currency for an income account if using trading accounts.  It would be better
to add a new account type for trading accounts, but that's a big deal and I'll
leave that for later after we see whether this set of changes is going to be
accepted or rejected.

17. Change gnc_xfer_dialog_run_exchange_dialog to understand that the new value
is really the split's amount if using trading accounts.

18. Changed xaccSplitGetOtherSplit to ignore trading splits if using commodity
exchange accounts.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18429 57a11ea4-9604-0410-9ed3-97b8803252fd
2009-11-20 20:11:03 +00:00