After much thrashing this turned out to be caused by a date string
with a 3-digit year and that caused an unexpected boost::bad_cast
exception from boost::posix_time::time_from_string().
To prevent that and anything like it, pre-parse the string with
regular expressions to classify them and split out the timezone
if there is one. If neither (perhaps eventually none) of the
regexes match throw std::invalid_argument. The C function will
catch this and return 0.
This is a bit brittle because it depends on Martin Preuss applying our
patch (already applied to borrowed/gwen-gtk3) before releasing 4.20.1,
but creating a proper test for the changes proved to be too difficult.
When fixing related combo error a couple of critical errors were logged
for 'Function is not appropriate for this type of widget' which turned
out to be visibility properties so added them to stop error.
If a GtkDialog builder description has the visible property set,
GtkBuilder will call gtk_window_show on it before we've had a chance
to call gtk_window_set_transient_for, and that raises a warning.
91f4b19 changed the test for gncInvoiceDateExists from date != 0
to date != INT64_MAX, which isn't backwards compatible, so test
for both. But the submitted file had a posted date of -1 so
gncInvoiceIsPosted returned true anyway. That's not consistent with
the logic in dialog-invoice.c, which checked gncInvoicePostedAcc != NULL,
a better test. The result was that the "Post" button lit up but
gncInvoicePost returned immediately, doing nothing, so change
gncInvoiceIsPosted to use gncInvoicePostedAcc instead.
Be smarter about what is path and key for each slot.
Instead of assuming a slash is always a path separator (first attempt
on unstable) or never a separator (second attempt),
track the parent path while loading kvp slots from the db
and deduce the slot's name by substracting this parent path.
Old code would nest a small single-row, 2-column html-table within the
entry-list html-table to display discount percentage and '%'. This is
an overkill and causes alignment issues. Display a string instead.
xaccSplitGetSharePrice will typically return a gnc-numeric (or scm
rational) value. This leads to the TR showing a price of, eg. $22 +
12228521/25349850 which is not ideal. This commit will modify the
share price to round the exact rational to an inexact decimal
according to the account share price currency SCU. If the SCU is less
than 10000, increase the precision by 2 significant digits.
There were several problems that broke the Imap Editor that have been
fixed due to kvp changes. The import-map-bayes entries were being added
to the tree view based on the number token entries squared. Retrieving
import-map entries resulted in an empty list and also deleting entries
from the tree view failed.