Commit Graph

23336 Commits

Author SHA1 Message Date
Frank H. Ellenberger
5671028ba3 L10N🇩🇪 Verbesserung translator-credits (von it.po) 2020-10-23 21:24:15 +02:00
Christopher Lam
78c8b03c5e [window-autoclear.c] cleanup, optimize, prevent UI lag
abort:
1. if too many splits lead to >1,000,000 reachable amounts
2. if the end_balance is the same as cleared_balance

also:
- g_free lists properly
- move knapsack algorithm to gnc-ui-balances.c
- show newly cleared splits in a new register: "Cleared Transactions"
- remove unneeded #includes
2020-10-23 09:11:29 +08:00
Frank H. Ellenberger
4bebfed9e8 Merge branch 'it.po' into maint 2020-10-23 01:26:52 +02:00
Giuseppe Foti
efb9226e4a L10N🇮🇹 Updated Italian translation; 5528 translated messagges. 2020-10-23 00:59:36 +02:00
Robert Fewell
3c5066feb4 Change source files option-util.* for spaces and tabs 2020-10-22 14:30:46 +01:00
Robert Fewell
e588695502 Change source files dialog-options.* for spaces and tabs 2020-10-22 14:30:11 +01:00
Robert Fewell
f93f850f17 Bug 345924 - Conditionally change Options dialog cancel button
When the options dialog is loaded, the main buttons are a sensitive
'Cancel' button and insensitive 'OK' and 'Apply' buttons. When changes
are made the 'OK' and 'Apply' buttons become sensitive and when pressed
the 'OK' button will make changes and close dialog whereas the 'Apply'
button will make changes and the dialog will remain open but with these
buttons insensitive leaving just 'Cancel' sensitive.

This could be confusing so this commit changes conditionally the text
label of the 'Cancel' button between 'Cancel' and 'Close'.
2020-10-22 14:27:54 +01:00
Robert Fewell
c11f4db96e Bug 345924 - Report options 'Reset Button' always flags changes
If a report is loaded with default settings and the 'Reset button' is
pressed the 'OK/Apply' buttons will be enabled which should not happen
as there are no changes to be made.

Fixed by resetting the changed flag on options load and then comparing
the current value to the default one when the 'Reset button' pressed.
2020-10-22 14:26:50 +01:00
Robert Fewell
8e5e3480ad Bug 797984 - Infinite loop while Check&Repair AR and AP accounts
If using the Check&Repair option from the Chart of Accounts on 'Account
Receivable or Payable' add has a voided transaction will cause an
infinite loop.

This occurs from checking the transaction split amount is zero in
gncScrubBusinessSplit and trying to delete it. As the transaction is
read only as a result of being voided this fails so add a further
condition for the 'else if' statement to include !is_void.
2020-10-20 14:45:44 +01:00
Robert Fewell
794b31a98e Change Registers abort_scrub to use gnc_*_abort_scrub functions 2020-10-20 14:45:14 +01:00
Robert Fewell
1be3b7808d Allow the Check&Repair to be cancellable on a Register page
Add a callback for a keypress event when on the Register page that
checks for the Escape key and presents a dialog to confirm whether to
abort the Check&Repair. A similar dialog is used if you decide to quit
Gnucash while the Check&Repair is still running.
2020-10-20 14:44:20 +01:00
Robert Fewell
122cd682f6 Add some additional places where Check&Repair can be aborted 2020-10-20 14:43:39 +01:00
Robert Fewell
6ee537e1a7 Allow the Check&Repair routine to be cancellable from CoA
Add a callback for a keypress event when on the Accounts page that
checks for the Escape key and presents a dialog to confirm whether to
abort the Check&Repair. A similar dialog is used if you decide to quit
Gnucash while the Check&Repair is still running.
2020-10-20 14:42:32 +01:00
John Ralls
94a68dca7c Bug 797983 - v4.2 report numbers change over gnucash restarts;...
Price Database dropping user:price-editor entries.

A wider problem: QofInstance was unmarking itself dirty as long as the
backend raised an error and unconditionally marking itself non-infant.

This matters because the SQL backend depends on infant status to decide
whether to do an insert or update query; either will fail if the infant
status is wrong.

The price editor dialog clones a price having only its commodity set and
GncSqlPriceBackend declines to save if the currency isn't set. Since the
instance marked itself non-infant even though it wasn't saved subsequent
commits tried to use an update query and since the price wasn't in the
table that inevitably failed.

Requiring that QofBackend::commit should doing the marking-clean
required implementing it in the backends where it wasn't already.
2020-10-18 16:09:41 -07:00
John Ralls
e255a7bfe2 Make the price database list obey the force-prices-to-decimal preference.
It was always displaying decimals regardless of the preference value.
2020-10-18 10:58:42 -07:00
Robert Fewell
190d5f1a61 Bug 797971 - Inserting description text behaves oddly
This is best observed when trying to insert a character, say x when the
cursor is before the last character, the cursor will jump to the end
like... ABCD|E results in ABCDxE|

It can also affect when inserting/changing text that has come from the
quick fill the cursor may end up in the wrong place.

Changed a test condition to use the incoming new character length value
instead of the existing cell one.
2020-10-15 15:21:05 +01:00
Bill Nottingham
06110e2abd Fix warning about misleading indentation from recent gcc.
Patch by <law@redhat.com>
2020-10-15 08:38:00 +08:00
Christopher Lam
305a3a8257 [auto-clear] default to cleared balance, select end_value
Because the user is expected to overwrite the end_value, by default we
select the end_value. Also select if erroring out.
2020-10-14 20:17:49 +08:00
Cristian Klein
2f366e58ff [auto-clear] Respect account balance reversal 2020-10-14 20:17:04 +08:00
Cristian Klein
e9f6703562 [auto-clear] Better explain the feature 2020-10-14 20:17:02 +08:00
Cristian Klein
1ab28db23f [auto-clear] Automatically add current balance 2020-10-14 20:17:00 +08:00
Frank H. Ellenberger
792d52b489 L10N: patch on "Cash en lieu"
Keep the perhaps not perfect translation for the default memo text
instead of English

Current state: language, translated, fuzzy, untranslated
ar.po: 4167, 893, 468.
as.po: 4131, 921, 476.
az.po: 111, 1353, 4064.
bg.po: 3099, 1686, 743.
brx.po: 4135, 917, 476.
ca.po: 4289, 862, 377.
cs.po: 2430, 2013, 1085.
da.po: 3544, 1173, 811.
de.po: 5512, 4, 12.
doi.po: 2912, 1848, 768.
el.po: 2913, 1558, 1057.
en_GB.po: 2688, 1664, 1176.
es.po: 4899, 471, 158.
es_NI.po: 797, 3018, 1713.
et.po: 487, 18, 5023.
eu.po: 1503, 2623, 1402.
fa.po: 2890, 971, 1667.
fi.po: 2684, 133, 2711.
fr.po: 3854, 1159, 515.
gu.po: 2929, 1823, 776.
he.po: 5457, 59, 12.
hi.po: 4091, 961, 476.
hr.po: 5458, 59, 11.
hu.po: 2984, 1578, 966.
id.po: 2778, 1629, 1121.
it.po: 5457, 58, 13.
ja.po: 5057, 221, 250.
kn.po: 4133, 919, 476.
ko.po: 2262, 1887, 1379.
kok.po: 4136, 916, 476.
kok@latin.po: 4069, 983, 476.
ks.po: 4032, 1020, 476.
lt.po: 3961, 982, 585.
lv.po: 4569, 707, 252.
mai.po: 4109, 943, 476.
mni.po: 4136, 916, 476.
mni@bengali.po: 4136, 916, 476.
mr.po: 4094, 957, 477.
nb.po: 2773, 1845, 910.
ne.po: 2399, 2121, 1008.
nl.po: 5024, 333, 171.
pl.po: 3433, 1599, 496.
pt.po: 5060, 348, 120.
pt_BR.po: 3695, 1382, 451.
ro.po: 2773, 1881, 874.
ru.po: 4360, 809, 359.
rw.po: 194, 2945, 2389.
sk.po: 2453, 1772, 1303.
sr.po: 4316, 842, 370.
sv.po: 2833, 788, 1907.
ta.po: 4131, 921, 476.
te.po: 4118, 934, 476.
tr.po: 4295, 749, 484.
uk.po: 5458, 57, 13.
ur.po: 4101, 951, 476.
vi.po: 2661, 1977, 890.
zh_CN.po: 3042, 1739, 747.
zh_TW.po: 2598, 1761, 1169.
2020-10-14 05:55:33 +02:00
Frank H. Ellenberger
99c3337189 L10N: Merge recent pot in all po files 2020-10-14 05:55:10 +02:00
Frank H. Ellenberger
73ea1f70c0 I18N: Add translator comments and fix capitalization for "Cash In Lieu" 2020-10-14 05:52:21 +02:00
Frank H. Ellenberger
f72edf5786 L10N🇫🇷 administrative clean up
Fix Chris' position
email of last translator and team must differ
reeorder translator-credit
remove obsolete entries
2020-10-14 05:29:16 +02:00
Frank H. Ellenberger
50e9c1ec52 Merge branch 'typo' into maint 2020-10-14 01:47:07 +02:00
Frank H. Ellenberger
752d887092 I18N: Redo the typo fix in gnc-plugin-page-register 2020-10-14 01:30:28 +02:00
Christopher Lam
2f31e65fac [fr.po] remove last-translator
not fluent enough
2020-10-14 07:26:41 +08:00
Frank H. Ellenberger
bef40540d4 Fix some errors found by i18nspector in po files
E: as.po: invalid-language Assamese => as
W: az.po: no-plural-forms-header-field 'nplurals=<n>; plural=<expression>'
W: az.po: invalid-date PO-Revision-Date: '2001-11-27 17:55GMT+0200' => '2001-11-27 17:55+0200'
P: bg.po: no-version-in-project-id-version 'GnuCash trunk'
W: brx.po: invalid-last-translator 'Ritu Panwar'
E: cs.po: unusual-plural-forms 'nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;' => 'nplurals=3; plural=n==1 ? 0 : (n>=2 && n<=4) ? 1 : 2;'
I: doi.po: language-team-equal-to-last-translator 'Dogri (doi) Chandrakant Dhutadmal <chandrakantd@cdac.in>' 'Chandrakant Dhutadmal <chandrakantd@cdac.in>'
P: en_GB.po: no-version-in-project-id-version en_GB
W: es_NI.po: language-disparity es_NI (pathname) != es (Language header field)
W: es_NI.po: no-plural-forms-header-field 'nplurals=2; plural=n != 1;'
P: es_NI.po: invalid-content-transfer-encoding 8-bit => 8bit
W: es_NI.po: invalid-last-translator 'Georg Lehner, Jorge.Lehner@gmx.net, Juan Manuel García Molina juanmagm@mail.com"'
E: eu.po: stray-header-line (empty string)
E: eu.po: leading-junk-in-plural-forms 'Plural-Forms: '
I: fa.po: boilerplate-in-initial-comments "Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER"
W: fr.po: invalid-last-translator 'Christopher Lam'
I: he.po: boilerplate-in-initial-comments 'FIRST AUTHOR: Ori Hoch <ori@uumpa.com>, 2008 http://www.uumpa.com/gnucash-he/'
I: he.po: language-team-equal-to-last-translator 'He <avi.markovitz@gmail.com>' 'Avi Markovitz <avi.markovitz@gmail.com>'
E: kn.po: invalid-language Kannada => kn
W: kok@latin.po: language-disparity 'kok@latin' (pathname) != 'kok@roman' (Language header field)
W: ko.po: no-plural-forms-header-field 'nplurals=1; plural=0;'
P: ko.po: no-version-in-project-id-version GnuCash
I: ko.po: language-team-equal-to-last-translator 'Korean <yongdoria@gmail.com>' 'Jin-Hwan Jeong <yongdoria@gmail.com>'
E: ks.po: invalid-language Kashmiri => ks
P: lt.po: no-version-in-project-id-version lt
I: mai.po: boilerplate-in-initial-comments 'This file is distributed under the same license as the PACKAGE package.'
E: mni@bengali.po: invalid-language 'Manipuri (Bengali Script)'
I: mni@bengali.po: no-package-name-in-project-id-version 2.6
E: mni.po: invalid-language 'Manipuri (MM)'
W: nb.po: language-disparity nb (pathname) != no (Language header field)
I: ne.po: boilerplate-in-initial-comments 'Copyright (C) YEAR Gnumatic, Inc.'
I: ne.po: unknown-header-field PO-Creation-Date
P: pl.po: no-version-in-project-id-version gnucash
I: pt_BR.po: no-package-name-in-project-id-version 2.2
E: pt.po: trailing-junk-in-plural-forms '\\n'
E: ta.po: invalid-language Tamil => ta
E: ur.po: invalid-language Urdu => ur
2020-10-13 23:42:27 +02:00
John Ralls
c8b725d48a Bug 797959 - "Exception" when value greater than one million with...
commas and periods is pasted to register.

Due to a use-after-free, but the underlying idea to remove the commas
from input to avoid a error dialog because of bad grouping was misguided
so revert to having the error dialog.
2020-10-13 13:17:30 -07:00
Christopher Lam
cca3be7c81 [window-autoclear.c] don't use g_str_hash on a double
use g_double_hash which is present since glib-2.22 now that minimum
glib is 2.56
2020-10-13 21:41:32 +08:00
Christopher Lam
44486a72a3 [window-autoclear.c] prepend instead of append
This knapsack algorithm is heavy on list manipulation. Speedup by
avoiding O(N^2) g_list_append. The list ordering is not useful in
knapsack, therefore there's no need to g_list_reverse.
2020-10-13 21:41:26 +08:00
Christopher Lam
f599925b89 Bug 797972 - Crash on export report CSV
omission of srfi-26 for (cut ...)
2020-10-11 23:00:29 +08:00
Robert Fewell
3587b4cc4b Tax Report Options appeared twice on menu for Chart of Accounts 2020-10-11 11:31:39 +01:00
Robert Fewell
8e220976be Some dialogs do not close with Escape key
These dialogs are based on GtkWindow and as such do not natively
respond to the escape key being pressed so to fix this a call back has
been added for 'key_press_event' which checks for the escape key.
2020-10-11 11:22:39 +01:00
Geert Janssens
05c96f6642 Make gnc-html's link libraries private 2020-10-10 16:09:39 +02:00
Geert Janssens
e8c321d954 Drop as dependency from gnc-module 2020-10-10 12:32:58 +02:00
Robert Fewell
f9e1f275d2 Change source files dialog-report-style-sheet.* for spaces and tabs 2020-10-08 16:02:15 +01:00
Robert Fewell
42094d3cc6 Bug 797956 - Dialog Report Style sheet not work well on Windows
When used on Windows, pressing the edit button would result in the
style sheet editor behind the selection dialog. To fix this change the
selection dialog to use a GtkWindow. This also helps when restoring
Gnucash from being minimised or covered by another application.
2020-10-08 15:23:21 +01:00
Christopher Lam
af9f7c85d4 [general-journal.scm] allow General/Title to render document title.
Previously would always override title with "General Journal". Modify
so that Report Title is set by default to "General Journal", but is
modifiable and will be rendered appropriately by the renderer.
2020-10-07 20:47:37 +08:00
Christopher Lam
d6d06d45de [general-journal.scm] fix whitespace 2020-10-07 20:45:48 +08:00
Christopher Lam
4905ffc889 Merge branch 'maint-owner-report-doclinks' into maint #795 2020-10-07 19:22:08 +08:00
Christopher Lam
7b1c9296ad [balsheet-pnl] use vector instead of list for report-dates
because report-dates were accessed via list-ref; vector-ref is O(1).
2020-10-07 19:22:00 +08:00
Christopher Lam
4ea142c486 [html-chart] use vector manipulation 2020-10-07 19:22:00 +08:00
Christopher Lam
39a6704169 [options.scm] rename new-owner-report "Links" to "Transaction Links" 2020-10-07 19:11:12 +08:00
Christopher Lam
0becf8cbc1 [new-owner-report] enable doclink links 2020-10-07 19:11:12 +08:00
Christopher Lam
abf052a213 [html-utilities][API] add gnc:html-invoice-doclink-anchor 2020-10-05 22:48:45 +08:00
Christopher Lam
f38a3506f3 [top-level] handle invoice-doclink-guid=InvoiceGUID urls 2020-10-05 22:47:53 +08:00
Robert Fewell
c587504c58 Correction to fix for Business 'Open Linked Document' sensitivity 2020-10-05 13:03:53 +01:00
Robert Fewell
f685a32d9a Bug 797967 - Manage Document Link errors
If there are no document links, the default dialog is for a file uri
and if the escape key is pressed in this default state the following
error is added to the trace file...
ERROR <Gtk> gtk_widget_event: assertion 'WIDGET_REALIZED_FOR_EVENT
(widget, event)' failed

This coming from the GtkFileChooserButton and to fix this add a signal
callback for the dialog 'key_press_event' to intercept the escape key
and emit a GTK_RESPONSE_CANCEL to close the dialog.
2020-10-05 13:03:53 +01:00