From 9189bcbe41dae281e8b7cf4ee34f7e3d89189070 Mon Sep 17 00:00:00 2001 From: John Ralls Date: Sun, 10 Nov 2019 12:30:15 -0800 Subject: [PATCH] Bug 797078 - "Automatic decimal point" Should Not Cause 2 Different Behaviors It's documented only for automatically inserting the decimal point so remove the code that affects number display. --- libgnucash/app-utils/gnc-ui-util.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/libgnucash/app-utils/gnc-ui-util.c b/libgnucash/app-utils/gnc-ui-util.c index eb149eb8d5..bae5f388bc 100644 --- a/libgnucash/app-utils/gnc-ui-util.c +++ b/libgnucash/app-utils/gnc-ui-util.c @@ -1553,18 +1553,9 @@ PrintAmountInternal(char *buf, gnc_numeric val, const GNCPrintAmountInfo *info) val = gnc_numeric_convert(val, denom, GNC_HOW_RND_ROUND_HALF_UP); value_is_decimal = gnc_numeric_to_decimal(&val, NULL); } - /* Force at least auto_decimal_places zeros */ - if (auto_decimal_enabled) - { - min_dp = MAX(auto_decimal_places, info->min_decimal_places); - max_dp = MAX(auto_decimal_places, info->max_decimal_places); - } - else - { - min_dp = info->min_decimal_places; - max_dp = info->max_decimal_places; - } - + min_dp = info->min_decimal_places; + max_dp = info->max_decimal_places; + /* Don to limit the number of decimal places _UNLESS_ force_fit is * true. */ if (!info->force_fit)