Commit Graph

15133 Commits

Author SHA1 Message Date
John Ralls
6fb2a93a85 Revert "Redo r23043 Don't print "warning" output in comparison functions."
Some extra files got pulled in...

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23063 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-25 17:04:30 +00:00
John Ralls
cd4f5d337d Redo r23043 Don't print "warning" output in comparison functions.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23062 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-25 16:49:16 +00:00
Christian Stimming
8237afd97f Bug #700804: Add up/down buttons for ordering of transactions in register2.
This changes the ordering but only for txn with the same date
and same number.  The buttons are active only in cases where this is
possible, otherwise the buttons are inactive anyway.

- for reconciled splits, user will be asked
- book-closing txn are ignored as well as frozen splits
- After changing the sort order, update the UI buttons immediately as well

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23061 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-23 07:57:40 +00:00
Christian Stimming
db8a08a3d0 Register2: Minor code cleanup: Rename moved_cb to uiupdate_cb. Refactor common sanity check into extra function.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23060 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-20 20:44:43 +00:00
Christian Stimming
a8516187b7 Bug #691587: Catch scheme exceptions when converting error messages to a C string.
When loading a scheme data file such as ~/.gnucash/stylesheets that contains
invalid characters (e.g., all-zero bytes), the loading throws a scheme
exception and we are redirected into the error catch handler. When trying
to convert the erroneous scheme expression into a string for the
message output, scheme runs into an exception right again. Hence, the
conversion to string must be guarded by a stack_catch as well.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23059 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:48:13 +00:00
Christian Stimming
d8a0015a3c Bug #669964: Fix txn creation that forgot to set a txn currency.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23058 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:48:02 +00:00
Christian Stimming
9b093abc4a Register2: Improve commodity/currency handling: Try to always use account_or_default_currency lookup instead of code duplication.
The code for ensuring a commodity that is a currency was duplicated among
the file. This is now refactored into the reg_currency variable. Also, in
a non-currency register the currency is now taken from parent accounts or
the default currency, which matches the old register's policy but is different
from what register2 previously did.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23057 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:47:49 +00:00
Christian Stimming
fd9ea2d808 Improve transaction currency lookup by using the new account_or_default currency getter.
Previously, this could result in transactions that have a non-currency as
txn commodity, which is what the multi-currency register tried to avoid hard.
Now by using account_or_default_currency, the currency choosing policy from
the register is available in the other places where new transactions are
created, hence we better use that here.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23056 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:47:39 +00:00
Christian Stimming
2bbcd7733f Refactor lookup of a commodity that is a currency for a specific account into general function gnc_account_or_default_currency().
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23055 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:47:27 +00:00
Christian Stimming
2ed03ccc57 Cutecash: Adapt cmake files to recent file moves.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23054 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-19 15:47:13 +00:00
Christian Stimming
8e524a4370 Bug #672595: After creation of a new book, make sure to set it to dirty so that a cancelled save_as dialog leaves the book dirty.
The missing part was the line in assistant-hierarchy.c, but I've added
it to the two other calls to file_access_for_save_as() to be on the safe
side on those two other book creation places as well.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23053 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-16 08:30:09 +00:00
Christian Stimming
511c970256 Bug #700582: Enable online actions in Register2
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23052 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-14 21:43:17 +00:00
Christian Stimming
bff5edbb66 Minor code cleanup (again from r23043): Don't print a warning in a comparison.
This only changes the single line that doesn't break the existing utest-Split.c

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23051 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-13 20:42:46 +00:00
Christian Stimming
c52ac5de5b Minor code cleanup: Decrease verbosity of register2 that makes the debugging output unreadable.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23050 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-13 20:25:24 +00:00
Christian Stimming
b5c4d37af3 Register2: Add more sanity checks when converting TreePaths from one to another.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23049 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-13 20:25:12 +00:00
Christian Stimming
581f27825e Revert r23043 "Minor code cleanup: Don't print "warning" output in comparison function."
Sigh. It turns out the utest-Split.c relies on the "warning" log level
in order to check for specific code paths. This sucks. The log level
"warning" should please be reserved for things that are actual warnings,
not for code path checks that are used in the unittests.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23048 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-13 07:58:49 +00:00
Christian Stimming
91b8b3c14d Had to partly revert r23045 when it comes to the PostedDate of book-closing txns.
The book-closing txn currently assume that their
posted-date is the end date plus 12 hours, so that the closing txn can
be distinguished from normal txns of the last day. This is the only
case within GnuCash where the PostedDate is a different time-of-day
that what the GDate normally says as a normalized date.

We better change this sometime in the future so that the PostedDate
doesn't silently contain this hidden extra meaning...

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23047 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-13 07:32:23 +00:00
Christian Stimming
bae4862575 Register (old+new): Duplicated transactions need a DateEntered as well.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23046 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-09 21:39:34 +00:00
Christian Stimming
85749ec058 Change all usage of xaccTransSetDatePostedSecs to xaccTransSetDatePostedSecsNormalized.
In fact, all calls to this setter refer to the plain date and not to
any time-of-day. Consequently, only the normalized setter must be used
everywhere. (Subsequently, the previous setter could be removed, as
it turned out to be not used anywhere, but that's another story.)

As a side effect, this makes the register2 set the PostedDate in the
same way as the old register again. The register2 used to introduce a
time-of-day part in the PostedDate, but this should not be done. Only
the EnteredDate has a time-of-day part.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23045 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-09 21:33:19 +00:00
Christian Stimming
697d228eb3 Introduce transaction setter xaccTransSetDatePostedSecsNormalized() that ignores the time-of-day part.
We've struggled with the time-of-day part of the PostedDate for long
enough. The PostedDate field is just not meaningful with anything else
but a plain date, and no time-of-day at all. Hence, the correct setter
function for this particular field must ignore the time-of-day. Consequently,
a GDate should be used here anyway, but in many places the time64 is more
convenient. The new function will now redirect that time64 to the GDate
setter function to make sure we will now map everything to one single date.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23044 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-09 21:32:06 +00:00
Christian Stimming
581871813d Minor code cleanup: Don't print "warning" output in comparison function.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23043 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-09 21:31:51 +00:00
Christian Stimming
5adb56bd77 Minor code cleanup: Don't use "class" as identifier.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23042 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-08 22:20:34 +00:00
Cristian Marchi
b3a57b2f1f Update Catalan translation, copied from the Translation Project.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23041 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-07 19:23:08 +00:00
Cristian Marchi
7afb55a12f Update Lithuanian translation thanks to Aurimas Fišeras.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23040 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-07 19:20:43 +00:00
Cristian Marchi
1549367840 Update Italian translation
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23039 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-07 19:02:48 +00:00
Geert Janssens
85f4dc6088 Report test makefiles: avoid extra softlinks for out-of-tree building
These are not necessary when the softlinks are created
directly to the original scm module files in the source directory.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23038 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-05 13:28:41 +00:00
Geert Janssens
a8ac55d010 Update .gitignore
New symbolic link:
test-driver -> /usr/share/automake-1.13/test-driver

Author:    Aurimas Fišeras <aurimas@members.fsf.org>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23037 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-04 21:28:45 +00:00
Geert Janssens
62e7cd4875 Use SCM_FILE_LINKS properly and some cleanups of report test makefiles
- Only some files need to be linked into a virtual guile module dir
  The others should be linked into the build dir if building out of tree
- Drop the .sh extension from test wrappers
- Move makefile variables and targets around a bit to be more consistent in the two makefiles

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23036 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-04 18:35:24 +00:00
Derek Atkins
f17d00842a Set SCM_FILE_LINKS even if not in a separate build directory, otherwise tests fail
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23035 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-04 00:20:09 +00:00
Geert Janssens
4f4130528e Fix distcheck and automake 1.13 build failure
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23034 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-03 21:59:59 +00:00
Geert Janssens
dfbd34c22f Reports: Reduce test verbosity
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23033 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-03 21:59:46 +00:00
Geert Janssens
2ec6708694 Win32: add VERSIONINFO block to RC file and convert in into a template to be completed during configure
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23032 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:55:13 +00:00
Geert Janssens
37733b9bc2 Win32: make sure RC file is actually considered for linking
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23031 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:55:03 +00:00
Geert Janssens
76ccb82013 Refactor so that we don't have to call gnc:progress functions while creating a report
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23030 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:34:41 +00:00
Geert Janssens
63441a3d6b reports: cleaned up a few methods in report-collectors
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23029 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:34:27 +00:00
Geert Janssens
f19a20af73 Reports: Deal with closing transactions.
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23028 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:33:59 +00:00
Geert Janssens
8aed5c3f66 reports: faster versions of category, net-barchart and net-linechart reports
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23027 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:33:27 +00:00
Geert Janssens
4d8d8bd76e Add test suite for standard tests
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23026 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:32:39 +00:00
Geert Janssens
72c7001693 Log a warning if a test shows more than 100% progress.
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23025 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:32:18 +00:00
Geert Janssens
4149b7ab87 Utils: Add "gnc:timepair?" function; useful for ensuring functions are called in a type-safe way.
Add gnc:timepair-next-day

Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23024 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:32:04 +00:00
Geert Janssens
7a3080d3dc Reports: Add collector functionality for side effects..
function-state->collector; turn a function/initial state into a collector
collector-do: Like collector-map, but only return the result of the first collector.
	It's assumed the other collectors are invoked for their side effects.

Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23023 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:31:51 +00:00
Geert Janssens
c30b3641a1 Reports: Add collector-into-list function.. turns the idea of adding stuff to a
list into a collector.

Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23022 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:31:39 +00:00
Geert Janssens
c57a3ee516 Add some plumbing for report changes - test framework plus some utility methods
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23021 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:31:26 +00:00
Geert Janssens
056545fcf8 Add exported ids to reports.. useful for testing
Author:    Peter Broadbery <p.broadbery@gmail.com>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23020 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-06-02 10:31:13 +00:00
Geert Janssens
3f908e8cb7 Bug 383928 - Bad command name: Remove transaction splits
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23019 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-31 17:03:14 +00:00
Geert Janssens
42e2bfdbe7 Update gitignore
Author:    Aurimas Fišeras <aurimas@members.fsf.org>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23015 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-28 10:40:04 +00:00
Geert Janssens
14ce35ff51 Update copyright year and make it translatable
Author:    Aurimas Fišeras <aurimas@members.fsf.org>

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23014 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-28 10:39:53 +00:00
John Ralls
e12bdcddcb Update Changelog for 2.5.2
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23012 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-27 20:56:25 +00:00
John Ralls
35d4affc46 Update NEWS for 2.5.2 release
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23010 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-27 18:44:39 +00:00
Christian Stimming
82f0f7d024 Win32 build: Update versions of gwenhywfar, aqbanking
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23006 57a11ea4-9604-0410-9ed3-97b8803252fd
2013-05-26 19:21:31 +00:00