* 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
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
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
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
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
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
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
- 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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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