Richard Cohen
1cec0cb3f3
Use internal extern "C" { ... } for C++
...
- removes warnings compiling swig engine
...
[ 10%] Generating swig-engine.cpp
.../libgnucash/engine/engine-helpers.h:31: Warning 313: Unrecognized extern type "C++".
.../libgnucash/engine/gnc-date.h:83: Warning 313: Unrecognized extern type "C++".
.../libgnucash/engine/qofquery.h:90: Warning 302: Identifier 'QofQuery' redefined (ignored),
.../libgnucash/engine/gnc-option.hpp:55: Warning 302: previous definition of 'QofQuery'.
.../libgnucash/engine/gnc-commodity.h:56: Warning 313: Unrecognized extern type "C++".
.../libgnucash/engine/gncBusiness.h:40: Warning 313: Unrecognized extern type "C++".
.../libgnucash/engine/gncEntry.h:37: Warning 313: Unrecognized extern type "C++".
2023-01-23 18:40:01 +00:00
John Ralls
9a1a90d8d0
Merge branch 'maint'
2023-01-22 10:49:29 -08:00
richardcohen
f3cc223f5f
Fix some bad code formatting
2023-01-22 10:39:48 -08:00
Christopher Lam
fd007a0af1
Merge branch 'maint'
2023-01-13 07:45:31 +08:00
Robert Fewell
6df866f876
Add tests for the reconcile account functions
2023-01-12 14:38:08 +00:00
Robert Fewell
fd37ee997d
Fix getting xaccAccountGetReconcilePostponeBalance
...
Change the G_VALUE from a INT64 to BOXED.
2023-01-12 14:38:08 +00:00
John Ralls
fb9947b7b6
Rename GncDateTime's ymd to gnc_ymd to avoid a name conflict with Carbon.
2023-01-09 14:36:06 -08:00
Christopher Lam
c65b36490a
Merge branch 'master-progress'
2023-01-06 16:33:46 +08:00
Frank H. Ellenberger
506a1b3c5e
Merge branch 'maint'
2023-01-06 01:31:13 +01:00
John Ralls
b922cfd78d
Bug 798679 - Unicode normalization should be used for comparison but not stored.
...
Change to NFC normalization for all comparisons because the Unicode
meaning of compatible might collide with the user's intent.
2023-01-04 13:19:36 -08:00
John Ralls
31d79e3004
Merge Bob Fewell's 'bug798673' into master.
2022-12-30 16:00:12 -08:00
Christopher Lam
259881f940
[gnc-optiondb] add some more renamed options
...
following ab13b01f8c Replace ... with … in all translatable strings.
2022-12-24 22:14:35 +08:00
John Ralls
ab13b01f8c
Replace ... with … in all translatable strings.
...
Also a few other places like translator comments and report options.
Replaces https://github.com/Gnucash/gnucash/pull/1033 .
2022-12-23 12:43:54 -08:00
John Ralls
b8c0673526
Merge branch 'maint'
2022-12-19 12:11:32 -08:00
Robert Fewell
3be25ff0a9
Add some tests for the account functions
2022-12-16 15:16:58 +00:00
Robert Fewell
a15c6f81b3
Allow the balances of sub accounts to be used in limits
2022-12-16 15:16:53 +00:00
John Ralls
73a134730f
Bug 798680 - Not able to match a reverse transaction of a...
...
previously matched transaction.
Cloned transactions and copied splits shouldn't keep the online-id
slot.
2022-12-13 13:13:13 -08:00
Robert Fewell
518ecfe041
Add some functions that would allow adding a balance limit to accounts
2022-12-10 13:37:41 +00:00
Christopher Lam
bfc325f63c
Merge branch 'maint'
2022-11-27 16:12:46 +08:00
Marco Scardovi
6fe2028bca
Fix test
...
Signed-off-by: Marco Scardovi <mscardovi@icloud.com >
2022-11-24 23:20:07 +01:00
Robert Fewell
59d95a4ce6
Bug 798545 - Crash when updating document link on vendor bill
...
There were two issues here, the first one was that the copied doclink
was pointing to the original doclink which lead to a double-free. The
second is the setting of the doclink on the copied invoice needs to be
done with gncInvoiceSetDocLink otherwise on closure the doclink value
will disappear.
2022-11-24 11:16:01 +00:00
Christopher Lam
3d8a28898d
[gnc-budget] gnc_budget_get_account_period_note returns a const
...
to harmonize with all other char getters
2022-11-19 10:35:49 +08:00
Christopher Lam
2ee0c98200
[gnc-budget] use operator[] instead of find() and insert()
...
- avoid hashing Account* twice. one call to operator[] is sufficient.
- don't need use std::move with better constructors
- sanity check - can't have a budget with num_periods = 0
- remove unused headers
2022-11-19 10:35:43 +08:00
Christopher Lam
3e5fcc8709
Merge branch 'maint'
2022-11-15 22:20:54 +08:00
Christopher Lam
6f80c548e6
[gtest-qofevent.cpp] comprehensive tests for qofevent
2022-11-05 09:25:24 +08:00
Christopher Lam
05ffd3d4eb
[budget-feature] move unset_feature call to gnc_budget_gui_delete_budget
...
because gnc_budget_gui_delete_budget is a more general function to
delete a budget.
2022-10-31 12:03:58 +08:00
Christopher Lam
b87aa004f9
[test-qofbook] add tests for unknown features
...
tests that gnc_features_test_unknown returns a suitable error message
2022-10-31 10:40:12 +08:00
John Ralls
b9077bccd3
Bug 798640 - Segfault when running saved report
2022-10-29 17:45:35 -07:00
Christopher Lam
fc94b41c81
Merge branch 'maint'
2022-10-29 21:53:57 +08:00
Christopher Lam
4716af24e4
Merge branch 'maint'
2022-10-29 21:16:34 +08:00
Christopher Lam
f2354d6b2a
[test-qofbook.c] add test for gnc_features_set_unused
2022-10-29 21:01:08 +08:00
Christopher Lam
1516bb18b0
[gnc-features.cpp] backport gnc_features_set_unused from master
2022-10-29 21:01:01 +08:00
Christopher Lam
a078921a33
[qofbook.cpp] backport qof_book_unset_feature from master
2022-10-29 21:00:54 +08:00
John Ralls
cf088f2a70
Merge John Ralls's 'Bug798614' into maint.
2022-10-28 15:27:28 -07:00
Christopher Lam
093aa81ed1
[qofbook.cpp] deprecate qof_book_get_features
2022-10-28 21:57:15 +08:00
Christopher Lam
8192deff37
[gnc-features.cpp] convert to cpp
...
- don't need to create/destroy GHashTable for each feature query
- plugs leak: g_hash_table_unref (features_used) not always called properly
- to check 1 feature, don't need to traverse whole GHashTable
2022-10-28 20:50:35 +08:00
Christopher Lam
6f6d2fef48
[test-qofbook] basic features test
...
sets a feature and tests it's set. it's impossible to design a book
with unknown features using the API.
2022-10-27 20:10:49 +08:00
Geert Janssens
e97fc3e408
Drop price-quotes.scm, gnc-fq-helper.in and gnc-fq-check.in - no longer used
2022-10-02 11:50:26 -07:00
Geert Janssens
a6771754d5
GncQuotes - start implementation of fetch/fetch_all
2022-10-02 11:50:25 -07:00
John Ralls
b0ae402c23
Limit instantiation of GncInt128 constructors to integral values.
...
Instead of using static_assert. This prevents the compiler from even
trying and avoids weird compilation errors when testing types for
instantiating other templates.
2022-10-02 10:15:15 -07:00
John Ralls
3c75d212ab
Fix build on Apple Silicon or maybe Apple-clang-14.0
...
The compiler complains that there's no matching
gnc_register_number_range_option for GncOptionDB*, which without this
commit is true because the explicit templates are for GncOptionDBPtr&.
Note that the original template definition is for GncOptionDB* and
that the header-defined inlines that take GncOptionDBPtr& call the
GncOptionDB* version.
2022-10-02 10:15:01 -07:00
John Ralls
8cb8f5067d
Remove non-ISO4217 currency codes from gnc-euro table.
...
They're not reachable because they don't have commodities associated with them.
2022-09-30 15:12:19 -07:00
John Ralls
d8417c3cfa
Move gnc-euro.[ch] to engine and unit test it.
2022-09-30 15:12:12 -07:00
John Ralls
2774f8f88c
Bug 798614 - Croatia to join the Euro
...
Add HRK to the conversion array.
2022-09-30 13:51:28 -07:00
John Ralls
3949821da6
Merge branch 'maint'
2022-09-25 11:50:10 -07:00
John Ralls
2505955ab9
Fix test failure from Bug 798616 fix.
2022-09-20 09:09:34 -07:00
John Ralls
7c350c3ae5
Bug 798616 - Can't register amount greater than 9,000,000,000
...
Because when loading the value the split in the xml backend doesn't yet
have a parent so the code tried to convert to GNC_COMMODITY_MAX_FRACTION
and if the numerator was larger than 10^10 that would overflow.
To fix it this changes the "don't know" response to get_currency_denom
and get_commodity_denom to GNC_DENOM_AUTO which will normally leave
the denominator alone.
2022-09-19 18:17:58 -07:00
Christopher Lam
161b07b241
Merge branch 'maint'
2022-09-09 21:23:40 +08:00
Frank H. Ellenberger
47fa8b281e
Merge PR #1425 into maint
2022-09-07 03:16:05 +02:00
John Ralls
a807d3e6b7
Create function gnc_tm_get_today_neutral.
...
To complement gnc_tm_get_today_begin and gnc_tm_get_today_end.
2022-09-06 14:35:11 -07:00