Merge branch 'maint'

This commit is contained in:
John Ralls 2022-09-25 11:50:10 -07:00
commit 3949821da6
12 changed files with 180 additions and 115 deletions

66
NEWS
View File

@ -1,5 +1,71 @@
Version history:
------- -------
4.12 - 25 September 2022
Between 4.11 and 4.12, the following bugfixes were accomplished:
Bug 794584 - Register not updated when scheduled transactions created
Bug 798262 - Scheduled transactions with blank amounts do not get created.
Bug 798385 - Description to often only "Landesbank Hessen-Thuringen Girozentrale"
Prepend the Ulitimate Creditor or Ultimate Debtor to the transaction description.
Bug 798565 - Import map editor: deletion of a map does not mark gnucash document as dirty
Bug 798573 - Tab Width Behaviour
Formerly when the notebook tabs on the left or right, the space used fluctuated depending on tab label width. This change sets the label width to the preference setting when the tabs are on the left or right but when top or bottom the width is set to the number of characters when shorter than the preference setting so they take up less room.
Bug 798578 - MT940 imports broken - all transactions have date of first transaction
Bug 798585 - segfault running sample script
simple_business_create.py.
Bug 798588 - sx scrubbing was using incorrect free function
Bug 798590 - Transaction report: wrong type argument in position 1
Bug 798598 - Selecting a line in a Vendor Credit Note changes display of Subtotal cell to 0.00
Bug 798611 - Date changing when changing timezone by one hour
When getting a date from the date editor anywhere in the program set the time to neutral time instead of the beginning of the day unless get_date_internal is called with GNC_DATE_EDIT_SHOW_TIME in which case the user-provided time is used.
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 in get_currency_denom and get_commodity_denom to GNC_DENOM_AUTO which will normally leave the denominator alone.
The following fixes and improvements were not associated with bug reports:
It is now possible to edit the description, notes, and memo fields of new transactions in the import matcher and to do so for multiple transactions. The option is accessed via a context menu on selected import lines.
Show GnuCash's installation and configuration configuration paths in the About dialog. List the same from the command line with a --paths option.
Add account hierarchy templates for locale es_AR
Continued work on the Stock Transaction Assistant. If you want to try out this new way of recording your investment transactions start GnuCash with the --extra option. The stock assistant is available on the toolbar and from the Actions menu when a register for a STOCK or FUND account is focused.
Replace the very obsolete ghelp: URI scheme with help: and install the documentation according to the XDG documentation spec on non-Mac Linux systems. This ensures that the Help menu documentation items work with Gnome 42 and later.
Conforming to the XDG documentation spec, rename the root page of the Help manual to index from help. This has the happy side effect of removing some special-case code from the macOS documentation links.
Standardize the top-level Equity and Assets account names in the French templates to "Capitaux propres" and "Actif" respectively.
[gnc-ab-utils] concise string accumulator
[gnc-glib-utils] gnc_g_list_stringjoin skips NULL data
[ifrs-cost-basis] identify sale/purchase according to truth table instead of via flawed heuristics
[ifrs-cost-basis] add options used as a report footer
[lot-viewer] Show Open & Close dates only when they have a value.
Fix use-after-free crash in gnc_set_busy_cursor.
Create Swiss SMB account chart acctchrt_pme-19.gnucash-xea.
[date-utilities] avoid report crash if start > end date
[html-chart] add percent formatter for numbers for older javascript.
[trial-balance] set default price-source to average-cost
to minimise complaints (see Bug 798550)
Use macos-latest github runner for mac tests.
[dialog-price] Price Database: Insert help buttons
Disable transaction type (i.e. Bill or Invoice) in Invoice/Bill Registers, determining the type by inspecting the money flow.
Fix python tests dependencies
So that ninja check works from a clean build directory with Python enabled.
Review of account templates C—missing placeholders, redundancies
Fixed a variety of fixed memory leaks, poor list handling, and dangling reference errors.
New API:
gnc_tm_get_today_neutral to complement gnc_tm_get_today_begin and
gnc_tm_get_today_end.
gnc_get_dialog_widget_from_id
gnc_list_all_paths
Deprecations: None.
New and Updated Translations: Basque, Chinese (Simplified), Croatian, Dutch, English (Australia), English (New Zealand), English (United Kingdom), French, German, Hebrew, Hungarian, Indonesian, Italian, Korean, Marathi, Polish, Portuguese, Portuguese (Brazil), Russian, Swedish, Ukrainian
4.11 - 26 June 2022
Between 4.10 and 4.11, the following bugfixes were accomplished:

View File

@ -38,6 +38,7 @@ extern "C" {
#include "assistant-stock-transaction.h"
#include "gnc-account-sel.h"
#include "gnc-amount-edit.h"
#include "gnc-prefs.h"
#include "gnc-component-manager.h"
#include "gnc-date-edit.h"
#include "gnc-tree-view-account.h"
@ -79,6 +80,7 @@ enum split_cols
SPLIT_COL_DEBIT,
SPLIT_COL_CREDIT,
SPLIT_COL_UNITS,
SPLIT_COL_UNITS_COLOR,
NUM_SPLIT_COLS
};
@ -261,7 +263,7 @@ reinvested must be subsequently recorded as a regular stock purchase.")
N_("Company redeems units, thereby increasing the stock price by a \
multiple, while keeping the total monetary value of the overall investment \
constant.\n\nIf the reverse split results in a cash in lieu for remainder \
units, please record the sale using the Stock Split Assistant first, then \
units, please record the sale using the Stock Transaction Assistant first, then \
record the reverse split.")
}
};
@ -367,15 +369,14 @@ static const TxnTypeVec short_types
N_("Company redeems units, thereby increasing the stock price by \
a multiple, while keeping the total monetary value of the overall investment \
constant.\n\nIf the reverse split results in a cash in lieu for remainder \
units, please record the cover buy using the Stock Split Assistant first, \
units, please record the cover buy using the Stock Transaction Assistant first, \
then record the reverse split.")
}
};
typedef struct
struct StockTransactionInfo
{
GtkWidget * window;
GtkWidget * assistant;
std::optional<TxnTypeVec> txn_types;
// the following stores date at which the txn_types were set. If
@ -441,7 +442,7 @@ typedef struct
GtkWidget * finish_page;
GtkWidget * finish_split_view;
GtkWidget * finish_summary;
} StockTransactionInfo;
};
/******* implementations ***********************************************/
@ -488,6 +489,22 @@ refresh_page_transaction_type (GtkWidget *widget, gpointer user_data)
info->txn_type->fees_capitalize);
}
static std::optional<gnc_numeric>
calculate_price (StockTransactionInfo* info)
{
gnc_numeric amount, value;
if (info->txn_type->stock_amount == FieldMask::DISABLED ||
info->txn_type->stock_value == FieldMask::DISABLED ||
gnc_amount_edit_expr_is_valid (GNC_AMOUNT_EDIT (info->stock_amount_edit), &amount, true, nullptr) ||
gnc_amount_edit_expr_is_valid (GNC_AMOUNT_EDIT (info->stock_value_edit), &value, true, nullptr))
return std::nullopt;
if (gnc_numeric_zero_p (amount) || gnc_numeric_zero_p (value))
return std::nullopt;
return gnc_numeric_div (value, amount, GNC_DENOM_AUTO, GNC_HOW_DENOM_EXACT);
}
static void
refresh_page_stock_amount (GtkWidget *widget, gpointer user_data)
@ -508,7 +525,7 @@ refresh_page_stock_amount (GtkWidget *widget, gpointer user_data)
{
gnc_numeric ratio = gnc_numeric_div (stock_amount, bal,
GNC_DENOM_AUTO, GNC_HOW_DENOM_REDUCE);
if (gnc_numeric_check (ratio) || gnc_numeric_negative_p (ratio))
if (gnc_numeric_check (ratio) || !gnc_numeric_positive_p (ratio))
gtk_label_set_text (GTK_LABEL(info->next_amount), nullptr);
else
{
@ -538,14 +555,10 @@ static void
refresh_page_stock_value (GtkWidget *widget, gpointer user_data)
{
auto info = static_cast<StockTransactionInfo*>(user_data);
gnc_numeric amount, value;
g_return_if_fail (info->txn_type);
if (info->txn_type->stock_amount == FieldMask::DISABLED ||
info->txn_type->stock_value == FieldMask::DISABLED ||
gnc_amount_edit_expr_is_valid (GNC_AMOUNT_EDIT (info->stock_amount_edit), &amount, true, nullptr) ||
gnc_amount_edit_expr_is_valid (GNC_AMOUNT_EDIT (info->stock_value_edit), &value, true, nullptr) ||
gnc_numeric_zero_p (value))
auto price = calculate_price (info);
if (!price.has_value())
{
// Translators: StockAssistant: N/A denotes stock price is not computable
const char* na_label = N_("N/A");
@ -553,9 +566,8 @@ refresh_page_stock_value (GtkWidget *widget, gpointer user_data)
return;
}
auto price = gnc_numeric_div (value, amount, GNC_DENOM_AUTO, GNC_HOW_RND_ROUND);
auto pinfo = gnc_commodity_print_info (info->currency, true);
gtk_label_set_text (GTK_LABEL (info->price_value), xaccPrintAmount (price, pinfo));
auto pinfo = gnc_price_print_info (info->currency, true);
gtk_label_set_text (GTK_LABEL (info->price_value), xaccPrintAmount (*price, pinfo));
}
static void
@ -608,6 +620,7 @@ struct SummaryLineInfo
std::string memo;
std::string value;
std::string units;
bool units_in_red;
};
static void
@ -623,6 +636,7 @@ add_to_summary_table (GtkListStore *list, SummaryLineInfo line)
SPLIT_COL_DEBIT, line.debit_side ? line.value.c_str() : "",
SPLIT_COL_CREDIT, !line.debit_side ? line.value.c_str() : "",
SPLIT_COL_UNITS, line.units.c_str(),
SPLIT_COL_UNITS_COLOR, line.units_in_red ? "red" : nullptr,
-1);
g_free (tooltip);
}
@ -640,6 +654,7 @@ check_page (SummaryLineInfo& line, gnc_numeric& debit, gnc_numeric& credit,
line.memo = gtk_entry_get_text (GTK_ENTRY (memo));
line.units = "";
line.units_in_red = false;
line.debit_side = (splitfield & FieldMask::ENABLED_DEBIT);
if (gnc_amount_edit_expr_is_valid (GNC_AMOUNT_EDIT (gae), &amount, true, nullptr))
@ -681,7 +696,7 @@ check_page (SummaryLineInfo& line, gnc_numeric& debit, gnc_numeric& credit,
line.account = "";
else
{
add_error (errors, N_("Account for %s is missing"), page);
add_error (errors, N_("Account for %s is missing."), page);
line.account = _(missing_str);
}
}
@ -704,6 +719,8 @@ refresh_page_finish (StockTransactionInfo *info)
gnc_numeric credit = gnc_numeric_zero ();
StringVec errors, warnings, infos;
SummaryLineInfo line;
bool negative_in_red = gnc_prefs_get_bool (GNC_PREFS_GROUP_GENERAL,
GNC_PREF_NEGATIVE_IN_RED);
// check the stock transaction date. If there are existing stock
// transactions dated after the date specified, it is very likely
@ -735,7 +752,7 @@ to ensure proper recording."), new_date_str, last_split_date_str);
}
if (info->txn_type->stock_value == FieldMask::DISABLED)
line = { false, false, xaccAccountGetName (info->acct), "", "", "" };
line = { false, false, xaccAccountGetName (info->acct), "", "", "", false };
else
check_page (line, debit, credit, info->txn_type->stock_value, info->acct,
info->stock_memo_edit, info->stock_value_edit, info->currency,
@ -756,14 +773,13 @@ to ensure proper recording."), new_date_str, last_split_date_str);
(xaccAccountGetCommodity (info->acct), true);
stock_amount = gnc_numeric_sub_fixed (stock_amount, info->balance_at_date);
line.units = xaccPrintAmount (stock_amount, stock_pinfo);
if (gnc_numeric_check (ratio))
add_error_str (errors, N_("Invalid stock new balance"));
else if (gnc_numeric_negative_p (ratio))
add_error_str (errors, N_("New and old balance must have same signs"));
line.units_in_red = negative_in_red && gnc_numeric_negative_p (stock_amount);
if (gnc_numeric_check (ratio) || !gnc_numeric_positive_p (ratio))
add_error_str (errors, N_("Invalid stock new balance."));
else if (gnc_numeric_negative_p (delta) && !credit_side)
add_error_str (errors, N_("New balance must be higher than old balance"));
add_error_str (errors, N_("New balance must be higher than old balance."));
else if (gnc_numeric_positive_p (delta) && credit_side)
add_error_str (errors, N_("New balance must be lower than old balance"));
add_error_str (errors, N_("New balance must be lower than old balance."));
}
else
{
@ -772,28 +788,26 @@ to ensure proper recording."), new_date_str, last_split_date_str);
auto stock_pinfo = gnc_commodity_print_info
(xaccAccountGetCommodity (info->acct), true);
if (!gnc_numeric_positive_p (stock_amount))
add_error_str (errors, N_("Stock amount must be positive"));
add_error_str (errors, N_("Stock amount must be positive."));
if (info->txn_type->stock_amount & FieldMask::ENABLED_CREDIT)
stock_amount = gnc_numeric_neg (stock_amount);
line.units = xaccPrintAmount (stock_amount, stock_pinfo);
line.units_in_red = negative_in_red && gnc_numeric_negative_p (stock_amount);
auto new_bal = gnc_numeric_add_fixed (info->balance_at_date, stock_amount);
if (gnc_numeric_positive_p (info->balance_at_date) &&
gnc_numeric_negative_p (new_bal))
add_error_str (errors, N_("Cannot sell more units than owned"));
add_error_str (errors, N_("Cannot sell more units than owned."));
else if (gnc_numeric_negative_p (info->balance_at_date) &&
gnc_numeric_positive_p (new_bal))
add_error_str (errors, N_("Cannot cover buy more units than owed"));
add_error_str (errors, N_("Cannot cover buy more units than owed."));
}
add_to_summary_table (list, line);
if (info->txn_type->stock_amount != FieldMask::DISABLED &&
info->txn_type->stock_value != FieldMask::DISABLED)
auto price = calculate_price (info);
if (price.has_value())
{
auto amt = gnc_amount_edit_get_amount (GNC_AMOUNT_EDIT(info->stock_amount_edit));
auto val = gnc_amount_edit_get_amount (GNC_AMOUNT_EDIT(info->stock_value_edit));
auto p = gnc_numeric_div (val, amt, GNC_DENOM_AUTO, GNC_HOW_DENOM_EXACT);
auto curr_pinfo = gnc_commodity_print_info (info->currency, true);
auto curr_pinfo = gnc_price_print_info (info->currency, true);
// Translators: %s refer to: stock mnemonic, broker currency,
// date of transaction.
auto tmpl = N_("A price of 1 %s = %s on %s will be recorded.");
@ -801,7 +815,7 @@ to ensure proper recording."), new_date_str, last_split_date_str);
auto price_str = g_strdup_printf
(_(tmpl),
gnc_commodity_get_mnemonic (xaccAccountGetCommodity (info->acct)),
xaccPrintAmount (p, curr_pinfo), date_str);
xaccPrintAmount (*price, curr_pinfo), date_str);
infos.emplace_back (price_str);
g_free (price_str);
g_free (date_str);
@ -1027,21 +1041,22 @@ create_split (Transaction *trans, FieldMask splitfield,
}
static void
add_price (GtkWidget *amount, GtkWidget *value,
gnc_commodity *commodity, gnc_commodity *currency, time64 date)
add_price (StockTransactionInfo* info, time64 date)
{
auto amt = gnc_amount_edit_get_amount (GNC_AMOUNT_EDIT (amount));
auto val = gnc_amount_edit_get_amount (GNC_AMOUNT_EDIT (value));
auto p = gnc_numeric_div (val, amt, GNC_DENOM_AUTO, GNC_HOW_DENOM_EXACT);
auto p = calculate_price (info);
if (!p.has_value())
return;
auto price = gnc_price_create (gnc_get_current_book ());
gnc_price_begin_edit (price);
gnc_price_set_commodity (price, commodity);
gnc_price_set_currency (price, currency);
gnc_price_set_commodity (price, xaccAccountGetCommodity (info->acct));
gnc_price_set_currency (price, info->currency);
gnc_price_set_time64 (price, date);
gnc_price_set_source (price, PRICE_SOURCE_STOCK_TRANSACTION);
gnc_price_set_typestr (price, PRICE_TYPE_UNK);
gnc_price_set_value (price, p);
gnc_price_set_value (price, *p);
gnc_price_commit_edit (price);
auto book = gnc_get_current_book ();
@ -1081,8 +1096,6 @@ stock_assistant_finish (GtkAssistant *assistant, gpointer user_data)
gae_amount (info->stock_amount_edit) : gnc_numeric_zero ();
auto stock_value = info->txn_type->stock_value != FieldMask::DISABLED ?
gae_amount (info->stock_value_edit) : gnc_numeric_zero ();
if (info->txn_type->input_new_balance)
stock_amount = gnc_numeric_sub_fixed (stock_amount, info->balance_at_date);
create_split (trans, info->txn_type->stock_amount | info->txn_type->stock_value,
NC_ ("Stock Assistant: Action field", "Stock"),
info->acct, account_commits, info->stock_memo_edit,
@ -1134,10 +1147,7 @@ stock_assistant_finish (GtkAssistant *assistant, gpointer user_data)
gnc_numeric_zero (), capgains, false, info);
}
if (info->txn_type->stock_amount != FieldMask::DISABLED &&
info->txn_type->stock_value != FieldMask::DISABLED)
add_price (info->stock_amount_edit, info->stock_value_edit,
xaccAccountGetCommodity (info->acct), info->currency, date);
add_price (info, date);
xaccTransCommitEdit (trans);
@ -1225,8 +1235,10 @@ get_treeview (GtkBuilder *builder, const gchar *treeview_label)
auto store = gtk_list_store_new (NUM_SPLIT_COLS, G_TYPE_STRING, G_TYPE_STRING,
G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING,
G_TYPE_STRING);
G_TYPE_STRING, G_TYPE_STRING);
gtk_tree_view_set_model(view, GTK_TREE_MODEL(store));
gtk_tree_selection_set_mode (gtk_tree_view_get_selection (view),
GTK_SELECTION_NONE);
g_object_unref(store);
auto renderer = gtk_cell_renderer_text_new();
@ -1259,7 +1271,10 @@ get_treeview (GtkBuilder *builder, const gchar *treeview_label)
gtk_cell_renderer_set_alignment (renderer, 1.0, 0.5);
gtk_cell_renderer_set_padding (renderer, 5, 0);
column = gtk_tree_view_column_new_with_attributes
(_("Units"), renderer, "text", SPLIT_COL_UNITS, nullptr);
(_("Units"), renderer,
"text", SPLIT_COL_UNITS,
"foreground", SPLIT_COL_UNITS_COLOR,
nullptr);
gtk_tree_view_append_column(view, column);
return GTK_WIDGET (view);

View File

@ -484,8 +484,8 @@ static GtkActionEntry gnc_plugin_page_register_actions [] =
G_CALLBACK (gnc_plugin_page_register_cmd_autoclear)
},
{
"ActionsStockAssistantAction", NULL, N_ ("Stock Ass_istant"), NULL,
N_ ("Stock Assistant"),
"ActionsStockAssistantAction", "applications-utilities",
N_ ("Stock Ass_istant"), NULL, N_ ("Stock Assistant"),
G_CALLBACK (gnc_plugin_page_register_cmd_stock_assistant)
},
{
@ -621,12 +621,6 @@ static const gchar* view_style_actions[] =
NULL
};
static const gchar* actions_requiring_extra[] =
{
"ActionsStockAssistantAction",
NULL
};
static const gchar* actions_requiring_priced_account[] =
{
"ActionsStockAssistantAction",
@ -1261,11 +1255,10 @@ gnc_plugin_page_register_ui_initial_state (GncPluginPageRegister* page)
gnc_plugin_update_actions (action_group, actions_requiring_account,
"sensitive", is_readwrite && account != NULL);
gnc_plugin_update_actions (action_group, actions_requiring_extra,
"visible", gnc_prefs_is_extra_enabled ());
gnc_plugin_update_actions (action_group, actions_requiring_priced_account,
"sensitive", account && xaccAccountIsPriced (account));
"visible", account &&
gnc_prefs_is_extra_enabled () &&
xaccAccountIsPriced (account));
/* Set "style" radio button */
ledger_type = gnc_ledger_display_type (priv->ledger);

View File

@ -6,7 +6,7 @@
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="border-width">12</property>
<property name="title" translatable="yes">Stock Split Assistant</property>
<property name="title" translatable="yes">Stock Transaction Assistant</property>
<property name="window-position">center</property>
<property name="default-width">500</property>
<signal name="cancel" handler="stock_assistant_cancel" swapped="no"/>

View File

@ -1020,14 +1020,17 @@ setup_entry (GtkWidget *entry, gboolean sensitive, GHashTable *hash,
GtkEntryCompletion* completion;
GtkListStore *list;
gtk_entry_set_text (GTK_ENTRY (entry), sensitive ? initial : _("Disabled"));
if (!sensitive)
gtk_entry_set_text (GTK_ENTRY (entry), _("Disabled"));
else if (initial && *initial)
gtk_entry_set_text (GTK_ENTRY (entry), initial);
gtk_widget_set_sensitive (entry, sensitive);
if (!sensitive)
return;
list = gtk_list_store_new (NUM_COMPLETION_COLS, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING);
g_hash_table_foreach (hash, (GHFunc)populate_list, list);
if (initial && !g_hash_table_lookup (hash, (gpointer)initial))
if (initial && *initial && !g_hash_table_lookup (hash, (gpointer)initial))
populate_list ((gpointer)initial, NULL, list);
gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (list),
COMPLETION_LIST_ORIGINAL,
@ -1676,6 +1679,10 @@ gnc_gen_trans_common_setup (GNCImportMainMatcher *info,
if (heading)
gtk_label_set_text (GTK_LABEL(heading_label), heading);
info->desc_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->notes_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->memo_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->new_strings = NULL;
info->transaction_processed_cb = NULL;
/* Connect the signals */
@ -1731,11 +1738,6 @@ gnc_gen_trans_list_new (GtkWidget *parent,
// This ensure this dialog is closed when the session is closed.
gnc_gui_component_set_session (info->id, gnc_get_current_session());
info->desc_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->notes_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->memo_hash = g_hash_table_new (g_str_hash, g_str_equal);
info->new_strings = NULL;
return info;
}

View File

@ -86,6 +86,7 @@
<separator name="ToolbarSep68"/>
<toolitem name="ToolbarTransfer" action="ActionsTransferAction"/>
<toolitem name="ActionsReconcile" action="ActionsReconcileAction"/>
<toolitem name="ActionsAssistant" action="ActionsStockAssistantAction"/>
</placeholder>
</toolbar>

View File

@ -1130,13 +1130,9 @@ xaccSplitDetermineGainStatus (Split *split)
static inline int
get_currency_denom(const Split * s)
{
if (!s)
if (!(s && s->parent && s->parent->common_currency))
{
return 0;
}
else if (!s->parent || !s->parent->common_currency)
{
return GNC_COMMODITY_MAX_FRACTION;
return GNC_DENOM_AUTO;
}
else
{
@ -1147,13 +1143,9 @@ get_currency_denom(const Split * s)
static inline int
get_commodity_denom(const Split * s)
{
if (!s)
if (!(s && s->acc))
{
return 0;
}
else if (!s->acc)
{
return GNC_COMMODITY_MAX_FRACTION;
return GNC_DENOM_AUTO;
}
else
{

View File

@ -760,10 +760,10 @@ test_get_currency_denom (Fixture *fixture, gconstpointer pData)
const gint denom = gnc_commodity_get_fraction (fixture->curr);
g_assert_cmpint (fixture->func->get_currency_denom (NULL), ==, 0);
fixture->split->parent = NULL;
g_assert_cmpint (fixture->func->get_currency_denom (fixture->split), ==, GNC_COMMODITY_MAX_FRACTION);
g_assert_cmpint (fixture->func->get_currency_denom (fixture->split), ==, GNC_DENOM_AUTO);
fixture->split->parent = txn;
txn->common_currency = NULL;
g_assert_cmpint (fixture->func->get_currency_denom (fixture->split), ==, GNC_COMMODITY_MAX_FRACTION);
g_assert_cmpint (fixture->func->get_currency_denom (fixture->split), ==, GNC_DENOM_AUTO);
txn->common_currency = fixture->curr;
g_assert_cmpint (fixture->func->get_currency_denom (fixture->split), ==, denom);
}
@ -778,7 +778,7 @@ test_get_commodity_denom (Fixture *fixture, gconstpointer pData)
const gint denom = gnc_commodity_get_fraction (fixture->comm);
g_assert_cmpint (fixture->func->get_commodity_denom (NULL), ==, 0);
fixture->split->acc = NULL;
g_assert_cmpint (fixture->func->get_commodity_denom (fixture->split), ==, GNC_COMMODITY_MAX_FRACTION);
g_assert_cmpint (fixture->func->get_commodity_denom (fixture->split), ==, GNC_DENOM_AUTO);
fixture->split->acc = acc;
g_assert_cmpint (fixture->func->get_commodity_denom (fixture->split), ==, denom);
}

View File

@ -11,6 +11,7 @@
# Adolfo Jayme Barrientos <fitojb@ubuntu.com>, 2021.
# Francisco Serrador <fserrador@gmail.com>, 2021, 2022.
# Cow <javier.fserrador@gmail.com>, 2022.
# Eduardo Malaspina <vaio0@swismail.com>, 2022.
#
#
# ###############################################################################
@ -77,12 +78,11 @@
msgid ""
msgstr ""
"Project-Id-Version: GnuCash 4.12-pre1\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug.cgi?"
"product=GnuCash&component=Translations\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug."
"cgi?product=GnuCash&component=Translations\n"
"POT-Creation-Date: 2022-09-11 23:24+0200\n"
"PO-Revision-Date: 2022-06-22 07:21+0000\n"
"Last-Translator: Jaime Marquínez Ferrándiz <weblate@jregistros.fastmail."
"net>\n"
"PO-Revision-Date: 2022-09-21 15:50+0000\n"
"Last-Translator: Eduardo Malaspina <vaio0@swismail.com>\n"
"Language-Team: Spanish <https://hosted.weblate.org/projects/gnucash/gnucash/"
"es/>\n"
"Language: es\n"
@ -90,11 +90,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.13.1-dev\n"
"X-Generator: Weblate 4.14.1\n"
"X-Bugs: Report translation errors to the Language-Team address.\n"
"X-Poedit-SourceCharset: UTF-8\n"
"X-Poedit-KeywordsList: <b>;</b>;<span weight=\"bold\" size=\"larger\">;</"
"span>;<span size=\"larger\" weight=\"bold\">\n"
"X-Poedit-KeywordsList: <b>;</b>;<span weight=\"bold\" size=\"larger\""
">;</span>;<span size=\"larger\" weight=\"bold\">\n"
#: borrowed/goffice/go-charmap-sel.c:70
msgid "Arabic"
@ -9267,7 +9267,7 @@ msgstr "Opciones del Libro"
#: gnucash/gnome-utils/gnc-main-window.c:4897 gnucash/gnucash-core-app.cpp:261
msgid "(user modifiable)"
msgstr ""
msgstr "(modificable por el usuario)"
#. Translators: %s will be replaced with the current year
#: gnucash/gnome-utils/gnc-main-window.c:4924

View File

@ -33,11 +33,11 @@
msgid ""
msgstr ""
"Project-Id-Version: GnuCash 4.12-pre1\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug.cgi?"
"product=GnuCash&component=Translations\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug."
"cgi?product=GnuCash&component=Translations\n"
"POT-Creation-Date: 2022-09-11 23:24+0200\n"
"PO-Revision-Date: 2022-09-11 09:20+0000\n"
"Last-Translator: Simon Arlott <weblate.simon@arlott.org>\n"
"PO-Revision-Date: 2022-09-23 19:20+0000\n"
"Last-Translator: Maxime Leroy <lisacintosh@gmail.com>\n"
"Language-Team: French <https://hosted.weblate.org/projects/gnucash/gnucash/"
"fr/>\n"
"Language: fr\n"
@ -45,7 +45,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"X-Generator: Weblate 4.14.1-dev\n"
"X-Generator: Weblate 4.14.1\n"
#: borrowed/goffice/go-charmap-sel.c:70
msgid "Arabic"
@ -2897,10 +2897,8 @@ msgstr "Chercher une prestation"
# po/guile_strings.txt:188
#: gnucash/gnome/dialog-lot-viewer.c:817
#, fuzzy
#| msgid "Empty space"
msgid "Empty"
msgstr "Espace vide"
msgstr "Vide"
# messages-i18n.c:310
#: gnucash/gnome/dialog-lot-viewer.c:829
@ -2908,7 +2906,7 @@ msgstr "Espace vide"
#| msgid "Open"
msgctxt "Adjective"
msgid "Open"
msgstr "Ouvrir"
msgstr "Ouvert"
# messages-i18n.c:261
#: gnucash/gnome/dialog-lot-viewer.c:923 gnucash/gnome/dialog-order.c:890

View File

@ -1,13 +1,14 @@
# Taehun Yun <yooontehoon@naver.com>, 2022.
# 이정희 <daemul72@gmail.com>, 2022.
# Minjae Isaac Kwon <minjae.isaac.kwon@gmail.com>, 2022.
msgid ""
msgstr ""
"Project-Id-Version: GnuCash 4.12-pre1\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug."
"cgi?product=GnuCash&component=Translations\n"
"POT-Creation-Date: 2022-09-11 23:24+0200\n"
"PO-Revision-Date: 2022-09-14 15:50+0000\n"
"Last-Translator: 이정희 <daemul72@gmail.com>\n"
"PO-Revision-Date: 2022-09-23 10:21+0000\n"
"Last-Translator: Minjae Isaac Kwon <minjae.isaac.kwon@gmail.com>\n"
"Language-Team: Korean <https://hosted.weblate.org/projects/gnucash/gnucash/"
"ko/>\n"
"Language: ko\n"
@ -15,7 +16,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 4.14.1-dev\n"
"X-Generator: Weblate 4.14.1\n"
"X-Poedit-Language: Korean\n"
"X-Poedit-Country: KOREA, REPUBLIC OF\n"
@ -599,7 +600,8 @@ msgstr ""
msgid ""
"To switch between multiple tabs in the main window, press Control+Page Up/"
"Down."
msgstr ""
msgstr "주 윈도우의 여러 탭을 이동하려면, Control 과 Page Up/Down 을 동시에 "
"입력하십시오."
#: doc/tip_of_the_day.list.c:82
msgid ""

View File

@ -14,10 +14,10 @@
msgid ""
msgstr ""
"Project-Id-Version: GnuCash 4.12-pre1\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug.cgi?"
"product=GnuCash&component=Translations\n"
"Report-Msgid-Bugs-To: https://bugs.gnucash.org/enter_bug."
"cgi?product=GnuCash&component=Translations\n"
"POT-Creation-Date: 2022-09-11 23:24+0200\n"
"PO-Revision-Date: 2022-08-11 07:18+0000\n"
"PO-Revision-Date: 2022-09-17 17:19+0000\n"
"Last-Translator: Arve Eriksson <031299870@telia.com>\n"
"Language-Team: Swedish <https://hosted.weblate.org/projects/gnucash/gnucash/"
"sv/>\n"
@ -26,7 +26,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.14-dev\n"
"X-Generator: Weblate 4.14.1-dev\n"
"X-Bugs: Report translation errors to the Language-Team address.\n"
#: borrowed/goffice/go-charmap-sel.c:70
@ -2682,14 +2682,10 @@ msgid "Find Job"
msgstr "Sök jobb"
#: gnucash/gnome/dialog-lot-viewer.c:817
#, fuzzy
#| msgid "Empty space"
msgid "Empty"
msgstr "Tomt utrymme"
msgstr "Tom"
#: gnucash/gnome/dialog-lot-viewer.c:829
#, fuzzy
#| msgid "Open"
msgctxt "Adjective"
msgid "Open"
msgstr "Öppna"