Commit Graph

26280 Commits

Author SHA1 Message Date
Christopher Lam
e6eb0f328c [assistant-stock-transaction] warn if TxnDate < latest Stock Txn 2022-05-04 21:43:00 +08:00
Christopher Lam
3f6962cfca [assistant-stock-transaction] refactor to allow warnings
Adds support for warnings, which can still allow creating a stock
transaction.
2022-05-04 21:43:00 +08:00
Robert Fewell
ee7ed89b68 This partly fixes the currency and commodity combos
With these changes the currency works but the commodity allows you to
set the commodity but will crash if you save config or leave report
open, this was tested on the 'Price scatter plot' report. Fixed with
John's commit a8e6a59
2022-05-03 16:55:55 +01:00
Robert Fewell
c6dff82b12 Toggle the sensitivity of date when using BothDateEntry 2022-05-03 16:55:55 +01:00
Robert Fewell
db6a8f809b Tax Tables combo does not set the active one
Fixed by correcting spelling of tax table qof type, should
'gncTaxTable'. Also fixed setting tax table combo to 'none' when page
reset button used.
2022-05-03 16:55:55 +01:00
Robert Fewell
5d15647430 Change some function alignments. 2022-05-03 16:55:55 +01:00
Robert Fewell
17cf31700d Move setting up the account select changed callback till after selecting default value. 2022-05-03 16:55:55 +01:00
Robert Fewell
d78a6b2d12 Segfault when leaving the properties option pages in hierarchy assistant
Segfaults when trying to retrieve the default budget value. Check for a
valid iter before trying to retrieve the budget.
2022-05-03 16:55:55 +01:00
Robert Fewell
91c7333aa2 Fix segfault when running hierarchy assistant
When the dialog options properties page is part of the hierarchy
assistant, the top level window has changed and so can no longer get
the option_win pointer so test for this being null before trying to
update the sensitivity of the buttons.
2022-05-03 16:55:55 +01:00
Robert Fewell
0b67a91217 Fix the option GncOptionRangeValue
The GncOptionRangeValue can be used with integers or doubles, the
default being doubles. When used for setting the plot width/height,
integers are used so all ValueTypes need to be integers other wise
the when create_range_spinner is used you end up with the upper_bound
value being G_MAXDOUBLE, a 309 character wide spin button. To
differentiate the two, use 'set_alternate(true)' for integers.
2022-05-03 16:55:48 +01:00
Robert Fewell
506eb38493 Update Chart Width/Height Plot setting
The new plot setting does both settings, values above 100 are treated
as pixels and ones below are treated as a percentage. This means the
maximum valid setting must be higher and also the tooltip needs to be
changed.
2022-05-03 15:44:24 +01:00
Robert Fewell
6e8272b7b3 Casting error on the terminal
Opening options dialog would generate the following error on the
terminal, invalid cast from 'GtkComboBox' to 'GNCDateEdit' which was
traced back to the RelativeDateEntry block_signals function. The
returned value of the cast was not being used so was removed.
2022-05-03 15:44:24 +01:00
Robert Fewell
3fcaaef657 Object reference error on terminal
Opening options dialog would generate the following error on the
terminal, g_object_ref: assertion 'G_IS_OBJECT (object)' failed which
was traced back to GncOptionDateUIItem trying to use a null pointer to
reference the GtkUIItem.
2022-05-03 15:44:24 +01:00
Robert Fewell
6d390dc6b4 Error in trace file, gtk_box_pack: assertion failed
In create_list_widget there was a duplicate set of lines that were
trying to pack the view into the same box widget.
2022-05-03 15:44:23 +01:00
Robert Fewell
b843dac2d1 Block the list selection changed signal
While the options dialog is loading, populating the GncGtkListUIItem
will cause the selection changed signal to be emitted and update the
options buttons but they are not yet available so block the signal.
2022-05-03 15:44:23 +01:00
Robert Fewell
adbc301499 Using an eventbox for tooltips is no longer required. 2022-05-03 15:44:23 +01:00
Robert Fewell
94105a19f1 GtkFontButton is deprecated, use GtkFontChooser instead 2022-05-03 15:44:23 +01:00
Robert Fewell
9cce53a627 Assistant hierarchy builder functions
With conversion of the source file to *.cpp the GtkBuilder connected
functions need to wrapped in a 'extern "C"' block.
2022-05-03 15:44:23 +01:00
Robert Fewell
b9e93d6e68 Limit saving dialog options window size
Only save the dialog options window size and location via the call
backs for the button press event. Using the destroy signal is not
suitable to save widget state as in this case the window position will
be (0,0).
2022-05-03 15:44:23 +01:00
John Ralls
1a186b953e [C++options] Correct handling of multichoice scheme option types.
Includes tests for save-to-scheme for each type.
2022-05-02 11:28:28 -07:00
Christopher Lam
f292ed66ab [assistant-stock-transaction.glade] don't translate placeholder text 2022-05-03 00:16:51 +08:00
Christopher Lam
56fa5949f9 use (string-concatenate ...) instead of (apply string-append ...)
similarly to a48e656ee, string-concatenate is less vulnerable to stack
overflow. this was confirmed by wingo some time back.
2022-05-02 20:59:37 +08:00
John Ralls
7e4fcc7afb https://bugs.gnucash.org/show_bug.cgi?id=798491
Prefer the entry date to the value date if present in the import.
The invalid date part of the bug was fixed in 7b1c050.
2022-04-29 16:51:48 -07:00
John Ralls
d62c6d96e3 [import matcher] Only append description if there's something to append to.
Otherwise just set the new string.
2022-04-29 15:52:21 -07:00
John Ralls
4d6dc384ee [import matcher] NULL protect g_utf8_normalize
It crashes if fed a NULL string.
May fix https://bugs.gnucash.org/show_bug.cgi?id=798483.
2022-04-29 15:52:05 -07:00
John Ralls
a8e6a59bf8 [C++options] Fix Guile crash when restoring some reports.
In particular those with commodity options or those using a stylesheet
whose name has spaces like "Head or Tail".
2022-04-29 11:16:25 -07:00
Szia Tomi
396c59e3d7
Translation update by Szia Tomi <sziatomi01@gmail.com> using Weblate
po/hu.po: 55.9% (3018 of 5390 strings; 1397 fuzzy)
529 failing checks (9.8%)
Translation: GnuCash/Program (Hungarian)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/hu/

Co-authored-by: Szia Tomi <sziatomi01@gmail.com>
2022-04-29 03:08:25 +02:00
Cow
5e9d0858d3
Translation update by Cow <javier.fserrador@gmail.com> using Weblate
po/es.po: 100.0% (5390 of 5390 strings; 0 fuzzy)
0 failing checks (0.0%)
Translation: GnuCash/Program (Spanish)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/es/

Co-authored-by: Cow <javier.fserrador@gmail.com>
2022-04-29 03:08:24 +02:00
Christopher Lam
7f316b8bdd [balsheet-pnl] test "lvl <= depth-limit" outside add-indented-row
this will be the first step trying to fix bug 798502. the bug likely
resides in the (if) conditional in (add-account-row).
2022-04-27 09:33:36 +08:00
Alex Aycinena
e381e70638 reverse commit d48937c. See discussion in Bug #79769. 2022-04-22 19:26:09 -07:00
Christopher Lam
3e109d0c37 remove deprecated functions in scheme 2022-04-22 13:45:13 +08:00
Christopher Lam
dc620d4b24 Merge branch 'maint' 2022-04-22 13:43:47 +08:00
Alex Aycinena
d48937cf9c Bug #79769 - Allow US Income Tax txf code 296 (Returns and allowances) to be shown and assignable for both income and expense type accounts. 2022-04-21 18:51:05 -07:00
Petter Reinholdtsen
55f1d62ff2
Translation update by Petter Reinholdtsen <pere-weblate@hungry.com> using Weblate
po/nb.po: 53.6% (2892 of 5390 strings; 1636 fuzzy)
397 failing checks (7.3%)
Translation: GnuCash/Program (Norwegian Bokmål)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/nb_NO/

Co-authored-by: Petter Reinholdtsen <pere-weblate@hungry.com>
2022-04-21 14:07:37 +02:00
Aleksandar Hadzhivelichkov
f9f76ffc76
Translation update by Aleksandar Hadzhivelichkov <Raphaelo245@gmail.com> using Weblate
po/glossary/bg.po: 85.1% (184 of 216 strings; 15 fuzzy)
10 failing checks (4.6%)
Translation: GnuCash/Glossary (Bulgarian)
Translate-URL: https://hosted.weblate.org/projects/gnucash/glossary/bg/

Co-authored-by: Aleksandar Hadzhivelichkov <Raphaelo245@gmail.com>
2022-04-21 14:07:36 +02:00
Kárász Attila
3d53af04b4
Translation update by Kárász Attila <cult.edie@gmail.com> using Weblate
po/glossary/hu.po: 85.6% (185 of 216 strings; 25 fuzzy)
2 failing checks (0.9%)
Translation: GnuCash/Glossary (Hungarian)
Translate-URL: https://hosted.weblate.org/projects/gnucash/glossary/hu/

Translation update  by Kárász Attila <cult.edie@gmail.com> using Weblate

po/hu.po: 55.9% (3018 of 5390 strings; 1397 fuzzy)
530 failing checks (9.8%)
Translation: GnuCash/Program (Hungarian)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/hu/

Co-authored-by: Kárász Attila <cult.edie@gmail.com>
2022-04-20 20:16:03 +02:00
ltai0001
823302ad55
Translation update by ltai0001 <yltaief@gmail.com> using Weblate
po/ar.po: 74.9% (4039 of 5390 strings; 874 fuzzy)
368 failing checks (6.8%)
Translation: GnuCash/Program (Arabic)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/ar/

Translation update  by ltai0001 <yltaief@gmail.com> using Weblate

po/ar.po: 74.9% (4038 of 5390 strings; 875 fuzzy)
371 failing checks (6.8%)
Translation: GnuCash/Program (Arabic)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/ar/

Translation update  by ltai0001 <yltaief@gmail.com> using Weblate

po/ar.po: 74.7% (4028 of 5390 strings; 885 fuzzy)
390 failing checks (7.2%)
Translation: GnuCash/Program (Arabic)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/ar/

Translation update  by ltai0001 <yltaief@gmail.com> using Weblate

po/ar.po: 74.6% (4026 of 5390 strings; 887 fuzzy)
395 failing checks (7.3%)
Translation: GnuCash/Program (Arabic)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/ar/

Translation update  by ltai0001 <yltaief@gmail.com> using Weblate

po/glossary/ar.po: 7.8% (17 of 216 strings; 0 fuzzy)
0 failing checks (0.0%)
Translation: GnuCash/Glossary (Arabic)
Translate-URL: https://hosted.weblate.org/projects/gnucash/glossary/ar/

Co-authored-by: ltai0001 <yltaief@gmail.com>
2022-04-20 20:16:03 +02:00
Alex Aycinena
178ef44d38 Bug 798471 - include hidden accounts in account tree view in Edit->Tax Report Options->Income Tax Information dialog. 2022-04-20 10:46:25 -07:00
Christopher Lam
efbc12b321 [gnc-main-window] page->window is not main_window, skip warning
This function gets called for both regular register *and* the embedded
register in the SX template editor. The latter is not a main_window,
and launching the SX editor would lead to warnings.
2022-04-19 23:00:26 +08:00
Christopher Lam
37791b608c [gnc-plugin-page-register] if account==NULL, skip AccountIsPriced
because gnc_plugin_page_register_ui_initial_state may be called for
non-account registers (eg the sx editor) and account may be null,
don't call xaccAccountIsPriced on null account.
2022-04-19 23:00:26 +08:00
Christopher Lam
394e0a4b71 [gnc-sx-instance-model.c] leak: don't strdup char* for xaccTransSetNotes
For a while now, xaccTransSetNotes would strdup the notes. Don't need
to strdup it beforehand.
2022-04-19 22:59:51 +08:00
Christopher Lam
27e5515c43 [gnc-account-sel.c] prepend & reverse while building acct list
and don't use confusing double pointer
2022-04-18 12:51:28 +08:00
154pinkchairs
639a88a05c
Translation update by 154pinkchairs <ovehis@riseup.net> using Weblate
po/pl.po: 62.1% (3352 of 5390 strings; 1529 fuzzy)
586 failing checks (10.8%)
Translation: GnuCash/Program (Polish)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/pl/

Co-authored-by: 154pinkchairs <ovehis@riseup.net>
2022-04-16 22:51:28 +02:00
Cow
a1ca43d11a
Translation update by Cow <javier.fserrador@gmail.com> using Weblate
po/es.po: 100.0% (5390 of 5390 strings; 0 fuzzy)
0 failing checks (0.0%)
Translation: GnuCash/Program (Spanish)
Translate-URL: https://hosted.weblate.org/projects/gnucash/gnucash/es/

Co-authored-by: Cow <javier.fserrador@gmail.com>
2022-04-16 22:51:28 +02:00
John Ralls
b4587e432f Fix use-after-free in unable to save database dialog. 2022-04-16 13:51:10 -07:00
Christopher Lam
de49a7e370 Merge branch 'maint-account-cpp' breadthwise search into maint #1319 2022-04-16 07:44:29 +08:00
Christopher Lam
e1d52963ed [account.cpp] restore breadth-first search for 2 functions
gnc_account_lookup_by_name and gnc_account_lookup_by_code were
searching breadth-first and accidentally changed to depth-first in
4.7.

as reported in https://github.com/Gnucash/gnucash/pull/1101#issuecomment-1098146573
2022-04-15 23:35:38 +08:00
Christopher Lam
07a9494d8d Merge branch 'maint-progress1' into maint #1306
export and use gnc_accounts_and_all_descendants
2022-04-15 12:27:31 +08:00
Christopher Lam
560f31250e [reports] use new function names
gnc:accounts-and-all-descendants-sorted
gnc-accounts-and-all-descendants
2022-04-15 12:23:57 +08:00
Christopher Lam
d2ad1aa35d [html-acct-table] deprecate gnc:account-path-less-p 2022-04-15 11:48:38 +08:00