gnucash future: Multiple changes pushed
Christopher Lam
clam at code.gnucash.org
Fri Sep 4 01:23:20 EDT 2026
Updated via https://github.com/Gnucash/gnucash/commit/b26e8b94 (commit)
via https://github.com/Gnucash/gnucash/commit/665503f8 (commit)
via https://github.com/Gnucash/gnucash/commit/a7a3e947 (commit)
via https://github.com/Gnucash/gnucash/commit/22e386a8 (commit)
via https://github.com/Gnucash/gnucash/commit/d8a1f045 (commit)
via https://github.com/Gnucash/gnucash/commit/5b60d213 (commit)
via https://github.com/Gnucash/gnucash/commit/ed1ed65f (commit)
via https://github.com/Gnucash/gnucash/commit/f5f133e1 (commit)
via https://github.com/Gnucash/gnucash/commit/284e7434 (commit)
via https://github.com/Gnucash/gnucash/commit/43a01b3c (commit)
via https://github.com/Gnucash/gnucash/commit/cf015139 (commit)
via https://github.com/Gnucash/gnucash/commit/a0608466 (commit)
via https://github.com/Gnucash/gnucash/commit/075ab569 (commit)
via https://github.com/Gnucash/gnucash/commit/a001e3e0 (commit)
via https://github.com/Gnucash/gnucash/commit/9b85edef (commit)
via https://github.com/Gnucash/gnucash/commit/a133dc00 (commit)
via https://github.com/Gnucash/gnucash/commit/8d261e03 (commit)
from https://github.com/Gnucash/gnucash/commit/ad5c8abd (commit)
commit b26e8b94b5ea56eece6e77cb56dde8f43f5083d0
Merge: ad5c8abd1f 665503f894
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Fri Sep 4 13:22:47 2026 +0800
Merge branch 'stable' into future
commit 665503f89487510f5ecb1cd292d10dc18c660421
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Tue Sep 1 18:08:26 2026 +0800
[import-export/test] add tests for gnc_import_parse_date|numeric
diff --git a/gnucash/import-export/test/CMakeLists.txt b/gnucash/import-export/test/CMakeLists.txt
index af2b1c0506..005284e2e8 100644
--- a/gnucash/import-export/test/CMakeLists.txt
+++ b/gnucash/import-export/test/CMakeLists.txt
@@ -18,6 +18,11 @@ gnc_add_test(test-import-pending-matches test-import-pending-matches.cpp
GENERIC_IMPORT_TEST_INCLUDE_DIRS GENERIC_IMPORT_TEST_LIBS
)
+set(GTEST_IMPORT_PARSE_LIBS gnc-generic-import gnc-test-engine test-core gtest)
+gnc_add_test(test-gnc-import-parse gtest-import-parse.cpp
+ GENERIC_IMPORT_TEST_INCLUDE_DIRS GTEST_IMPORT_PARSE_LIBS
+)
+
set(IMPORT_ACCOUNT_MATCHER_TEST_INCLUDE_DIRS
${CMAKE_BINARY_DIR}/common # for config.h
${CMAKE_SOURCE_DIR}/gnucash/import-export
@@ -87,6 +92,7 @@ gnc_add_test(test-import-backend "${gtest_import_backend_SOURCES}"
set_dist_list(test_generic_import_DIST
CMakeLists.txt
test-import-parse.c
+ gtest-import-parse.cpp
test-import-pending-matches.cpp
gtest-import-account-matcher.cpp
gtest-import-backend.cpp)
diff --git a/gnucash/import-export/test/gtest-import-parse.cpp b/gnucash/import-export/test/gtest-import-parse.cpp
new file mode 100644
index 0000000000..d2991e3b33
--- /dev/null
+++ b/gnucash/import-export/test/gtest-import-parse.cpp
@@ -0,0 +1,213 @@
+/********************************************************************
+ * gtest-import-parse.cpp -- unit tests for import-parse.cpp *
+ * *
+ * This program is free software; you can redistribute it and/or *
+ * modify it under the terms of the GNU General Public License as *
+ * published by the Free Software Foundation; either version 2 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License*
+ * along with this program; if not, contact: *
+ * *
+ * Free Software Foundation Voice: +1-617-542-5942 *
+ * 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652 *
+ * Boston, MA 02110-1301, USA gnu at gnu.org *
+ * *
+ *******************************************************************/
+
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wcpp"
+#include <gtest/gtest.h>
+#pragma GCC diagnostic pop
+
+#include <config.h>
+#include "import-parse.h"
+
+/* ------------------------------------------------------------------ *
+ * gnc_import_test_numeric
+ * ------------------------------------------------------------------ */
+
+class ImportTestNumeric : public ::testing::TestWithParam<
+ std::tuple<const char*, GncImportFormat>>
+{
+};
+
+TEST_P (ImportTestNumeric, Cases)
+{
+ static constexpr auto fmts =
+ static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA);
+ const auto& [str, expected] = GetParam();
+ EXPECT_EQ (gnc_import_test_numeric (str, fmts), expected) << "str=" << str;
+}
+
+INSTANTIATE_TEST_SUITE_P (Unambiguous, ImportTestNumeric, ::testing::Values(
+ std::make_tuple ("123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple ("123,45", GNCIF_NUM_COMMA),
+ std::make_tuple ("1.182.183,1827", GNCIF_NUM_COMMA),
+ std::make_tuple ("1,182,183.1827", GNCIF_NUM_PERIOD)
+));
+
+INSTANTIATE_TEST_SUITE_P (Ambiguous, ImportTestNumeric, ::testing::Values(
+ /* a plain integer, or a thousands-group without a decimal part, is
+ * valid under either convention */
+ std::make_tuple ("2000", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA)),
+ std::make_tuple ("1,000", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA)),
+ std::make_tuple ("1.000", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA)),
+ std::make_tuple ("-$1,000", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA)),
+ /* a 3-digit thousands-group with no decimal part reads equally well
+ * as "one hundred point two hundred seventy-seven thousand" under
+ * the other convention's grouping rules */
+ std::make_tuple ("100.277", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA)),
+ std::make_tuple ("100,277", static_cast<GncImportFormat>(GNCIF_NUM_PERIOD | GNCIF_NUM_COMMA))
+));
+
+INSTANTIATE_TEST_SUITE_P (SignsAndCurrency, ImportTestNumeric, ::testing::Values(
+ std::make_tuple ("-123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple ("+123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple ("$123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple ("$-123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple ("-$123.45", GNCIF_NUM_PERIOD),
+ std::make_tuple (" $+2000.00", GNCIF_NUM_PERIOD),
+ /* the pattern only allows a leading '$', never a trailing one */
+ std::make_tuple ("123.45$", GNCIF_NONE)
+));
+
+INSTANTIATE_TEST_SUITE_P (Invalid, ImportTestNumeric, ::testing::Values(
+ std::make_tuple ("abc", GNCIF_NONE),
+ std::make_tuple ("123.45.67", GNCIF_NONE),
+ std::make_tuple ("12,34,5", GNCIF_NONE),
+ std::make_tuple ("1-2", GNCIF_NONE)
+));
+
+/* ------------------------------------------------------------------ *
+ * gnc_import_test_date
+ * ------------------------------------------------------------------ */
+
+class ImportTestDate : public ::testing::TestWithParam<
+ std::tuple<const char*, GncImportFormat>>
+{
+};
+
+TEST_P (ImportTestDate, Cases)
+{
+ static constexpr auto fmts = static_cast<GncImportFormat>(
+ GNCIF_DATE_DMY | GNCIF_DATE_MDY | GNCIF_DATE_YMD | GNCIF_DATE_YDM);
+ const auto& [str, expected] = GetParam();
+ EXPECT_EQ (gnc_import_test_date (str, fmts), expected) << "str=" << str;
+}
+
+INSTANTIATE_TEST_SUITE_P (Unambiguous, ImportTestDate, ::testing::Values(
+ std::make_tuple ("1999/12/31", GNCIF_DATE_YMD),
+ std::make_tuple ("2001-6-17", GNCIF_DATE_YMD),
+ std::make_tuple ("20020726", GNCIF_DATE_YMD),
+ std::make_tuple ("1999/31/12", GNCIF_DATE_YDM),
+ std::make_tuple ("2001-17-6", GNCIF_DATE_YDM),
+ std::make_tuple ("1/16/2001", GNCIF_DATE_MDY),
+ std::make_tuple ("12-31-1999", GNCIF_DATE_MDY),
+ std::make_tuple ("16/1/2001", GNCIF_DATE_DMY),
+ std::make_tuple ("31-12-1999", GNCIF_DATE_DMY),
+ /* the apostrophe and '.' separators are also accepted, not just '-' and '/' */
+ std::make_tuple ("1999.12.31", GNCIF_DATE_YMD),
+ std::make_tuple ("1999'12'31", GNCIF_DATE_YMD)
+));
+
+INSTANTIATE_TEST_SUITE_P (Ambiguous, ImportTestDate, ::testing::Values(
+ std::make_tuple ("99/1/6", static_cast<GncImportFormat>(GNCIF_DATE_YMD | GNCIF_DATE_YDM)),
+ std::make_tuple ("1/3/99", static_cast<GncImportFormat>(GNCIF_DATE_DMY | GNCIF_DATE_MDY))
+));
+
+INSTANTIATE_TEST_SUITE_P (OutOfRange, ImportTestDate, ::testing::Values(
+ /* first field > 31: can't be a day or month, and as a year it's
+ * outside [1930, 2100], so nothing survives */
+ std::make_tuple ("40/1/2020", GNCIF_NONE),
+ /* year (1929) below the accepted [1930, 2100] range */
+ std::make_tuple ("1929-01-01", GNCIF_NONE),
+ /* year (2101) above the accepted range */
+ std::make_tuple ("2101-01-01", GNCIF_NONE),
+ /* a single-digit first field can't be a 4-digit year */
+ std::make_tuple ("1/2/2020", static_cast<GncImportFormat>(GNCIF_DATE_DMY | GNCIF_DATE_MDY)),
+ /* month field (13) out of range for every format that needs a
+ * month there */
+ std::make_tuple ("13/13/2020", GNCIF_NONE)
+));
+
+INSTANTIATE_TEST_SUITE_P (Invalid, ImportTestDate, ::testing::Values(
+ std::make_tuple ("not a date", GNCIF_NONE),
+ std::make_tuple ("2020", GNCIF_NONE)
+));
+
+/* ------------------------------------------------------------------ *
+ * gnc_import_parse_date
+ * ------------------------------------------------------------------ */
+
+struct YMD { int y; int m; int d; };
+
+class ImportParseDate : public ::testing::TestWithParam<
+ std::tuple<const char*, GncImportFormat, YMD>>
+{
+};
+
+TEST_P (ImportParseDate, Cases)
+{
+ const auto& [str, fmt, expected] = GetParam();
+ time64 val;
+ ASSERT_TRUE (gnc_import_parse_date (str, fmt, &val)) << "str=" << str;
+ time64 expected_val = gnc_dmy2time64 (expected.d, expected.m, expected.y);
+ EXPECT_EQ (val, expected_val) << "str=" << str;
+}
+
+INSTANTIATE_TEST_SUITE_P (Formats, ImportParseDate, ::testing::Values(
+ std::make_tuple ("1999/12/31", GNCIF_DATE_YMD, YMD{1999, 12, 31}),
+ std::make_tuple ("2001-6-17", GNCIF_DATE_YMD, YMD{2001, 6, 17}),
+ std::make_tuple ("20020726", GNCIF_DATE_YMD, YMD{2002, 7, 26}),
+ std::make_tuple ("1999/31/12", GNCIF_DATE_YDM, YMD{1999, 12, 31}),
+ std::make_tuple ("20012311", GNCIF_DATE_YDM, YMD{2001, 11, 23}),
+ std::make_tuple ("1/16/2001", GNCIF_DATE_MDY, YMD{2001, 1, 16}),
+ std::make_tuple ("01171983", GNCIF_DATE_MDY, YMD{1983, 1, 17}),
+ std::make_tuple ("16/1/2001", GNCIF_DATE_DMY, YMD{2001, 1, 16}),
+ std::make_tuple ("17011976", GNCIF_DATE_DMY, YMD{1976, 1, 17})
+));
+
+/* Y2K fixups performed by the fix_year() helper: two-digit years below
+ * 70 are 20xx, otherwise 19xx. (A literal "00" year can't reach fix_year
+ * at all - the v2 > 0 format-validation check above rejects it first,
+ * same as it always has - so it's not exercised here.)
+ */
+INSTANTIATE_TEST_SUITE_P (Y2K, ImportParseDate, ::testing::Values(
+ std::make_tuple ("01/02/01", GNCIF_DATE_MDY, YMD{2001, 1, 2}),
+ std::make_tuple ("01/02/69", GNCIF_DATE_MDY, YMD{2069, 1, 2}),
+ std::make_tuple ("01/02/70", GNCIF_DATE_MDY, YMD{1970, 1, 2}),
+ std::make_tuple ("01/02/99", GNCIF_DATE_MDY, YMD{1999, 1, 2})
+));
+
+TEST (ImportParseDate, InvalidFormatCombination)
+{
+ time64 val;
+ /* out-of-range month for the given format */
+ EXPECT_FALSE (gnc_import_parse_date ("13/13/2020", GNCIF_DATE_MDY, &val));
+ /* not a date at all */
+ EXPECT_FALSE (gnc_import_parse_date ("not a date", GNCIF_DATE_MDY, &val));
+}
+
+/* ------------------------------------------------------------------ *
+ * gnc_import_parse_numeric
+ * ------------------------------------------------------------------ */
+
+TEST (ImportParseNumeric, PeriodAndCommaAgree)
+{
+ gnc_numeric pval, cval;
+ ASSERT_TRUE (gnc_import_parse_numeric ("1,182,183.1827", GNCIF_NUM_PERIOD, &pval));
+ ASSERT_TRUE (gnc_import_parse_numeric ("1.182.183,1827", GNCIF_NUM_COMMA, &cval));
+ EXPECT_TRUE (gnc_numeric_equal (pval, cval));
+}
+
+TEST (ImportParseNumeric, InvalidString)
+{
+ gnc_numeric val;
+ EXPECT_FALSE (gnc_import_parse_numeric ("not a number", GNCIF_NUM_PERIOD, &val));
+}
commit a7a3e947fb5cb62c678c085b1bba3ecbc0a2ea0d
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Thu Sep 3 19:39:07 2026 +0800
[import-parse.cpp] compile regex before trying to parse dates
diff --git a/gnucash/import-export/import-parse.cpp b/gnucash/import-export/import-parse.cpp
index f4d8b52326..1c07c43c60 100644
--- a/gnucash/import-export/import-parse.cpp
+++ b/gnucash/import-export/import-parse.cpp
@@ -306,6 +306,9 @@ gnc_import_parse_date(const char *str, GncImportFormat fmt, time64 *val)
int v0 = 0, v1 = 0, v2 = 0;
int m = 0, d = 0, y = 0;
+ if (!regex_compiled)
+ compile_regex();
+
g_return_val_if_fail(str, FALSE);
g_return_val_if_fail(val, FALSE);
g_return_val_if_fail(fmt, FALSE);
commit 22e386a89a56663ca0f45c6095caade896bae444
Merge: 075ab5690f d8a1f045f4
Author: John Ralls <jralls at ceridwen.us>
Date: Tue Sep 1 11:44:52 2026 -0700
Merge PRG-112's 'chart-tooltip-improvements' into stable.
commit d8a1f045f4f6834ab08e8d35a5176282e83214e7
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Mon Aug 24 11:42:33 2026 +0200
Tweaks and cleanups
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index 6841d29a2f..a97574344d 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -71,8 +71,6 @@
(export gnc:html-chart-add-data-series!)
(export gnc:html-chart-apply-preferences-report!)
-(define gnc:showTooltipNonZerOnly #f)
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; utility functions for nested list handling
@@ -221,12 +219,10 @@
(cons 'tooltips (list
(cons 'mode 'index)
(cons 'intersect #f)
- (cons 'cornerRadius 5)
- (cons 'backgroundColor "rgba(33, 33, 33, 0.95)")
+ (cons 'backgroundColor "rgba(36, 36, 36, 0.94)")
(cons 'titleMarginBottom 14)
- (cons 'titleAlign 'left)
(cons 'xPadding 8)
- (cons 'yPadding 8)
+ (cons 'yPadding 9)
(cons 'bodySpacing 3)
(cons 'callbacks (list
(cons 'label #f)))))
@@ -305,10 +301,8 @@
(gnc:html-chart-set! chart '(options scales xAxes (0) type) type))
(define (gnc:html-chart-set-tooltip-indexed?! chart indexed?)
- (if indexed?
- (gnc:html-chart-set! chart '(options tooltips mode) 'index)
- (gnc:html-chart-set! chart '(options tooltips mode) 'point)
-))
+ (gnc:html-chart-set! chart '(options tooltips mode) (if indexed? 'index 'point))
+)
(define (gnc:html-chart-set-tooltip-non-zero-only! chart nonZeroOnly)
(gnc:html-chart-set! chart '(options tooltips showNonZeroOnly) nonZeroOnly))
@@ -421,7 +415,7 @@ function tooltipLabel(tooltipItem,data) {
var label = data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index];
switch (typeof(label)) {
case 'number':
- return ' ' + datasetLabel + ' : ' + numformat(label) + ' ';
+ return ' \u200A' + datasetLabel + ' : ' + numformat(label) + ' ';
default:
return '';
}
commit 5b60d213aec85994ae0df89803f7612b4060e3f2
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Sun Aug 23 19:46:24 2026 +0200
Enhancement - even more readable tooltip
- tooltip background - less transparent, more readable with barcharts
- more space between entries (vertically, ++1px)
- a slightly more spacious edges of the poopup (horizontally)
- entries will end slightly further from the right edge
- bigger margin below a title
Screenshots based on: GC Sample Database: https://github.com/PRG-112/gnucash-sample-db-generator
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index f5d202f852..6841d29a2f 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -221,6 +221,13 @@
(cons 'tooltips (list
(cons 'mode 'index)
(cons 'intersect #f)
+ (cons 'cornerRadius 5)
+ (cons 'backgroundColor "rgba(33, 33, 33, 0.95)")
+ (cons 'titleMarginBottom 14)
+ (cons 'titleAlign 'left)
+ (cons 'xPadding 8)
+ (cons 'yPadding 8)
+ (cons 'bodySpacing 3)
(cons 'callbacks (list
(cons 'label #f)))))
@@ -414,7 +421,7 @@ function tooltipLabel(tooltipItem,data) {
var label = data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index];
switch (typeof(label)) {
case 'number':
- return ' ' + datasetLabel + ' : ' + numformat(label);
+ return ' ' + datasetLabel + ' : ' + numformat(label) + ' ';
default:
return '';
}
@@ -424,7 +431,7 @@ function tooltipTitle(array,data) {
if (!data || array.length === 0) {
return '';
}
- return data.labels[array[0].index];
+ return data.labels[array[0].index] + ' ';
}
function tooltipFilter(tooltipItem, data) {
commit ed1ed65faf1ad963925fc4108b6323f1188a9eac
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Sun Aug 23 16:05:29 2026 +0200
CI Tests - Fix
the Pull Requests is passing tests with this fix now.
diff --git a/gnucash/report/reports/standard/account-piecharts.scm b/gnucash/report/reports/standard/account-piecharts.scm
index d5c95869a4..9aa442c82a 100644
--- a/gnucash/report/reports/standard/account-piecharts.scm
+++ b/gnucash/report/reports/standard/account-piecharts.scm
@@ -339,9 +339,6 @@ balance at a given time"))
(gnc-account-get-children-sorted
(gnc-get-current-root-account)))))
- ;; apply default settings from preferences
- (gnc:html-chart-apply-preferences-report! chart)
-
;; Returns true if the account a was selected in the account
;; selection option.
(define (show-acct? a)
@@ -502,6 +499,9 @@ balance at a given time"))
(define (round-scu amt)
(gnc-numeric-convert amt scu GNC-HOW-RND-ROUND))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
(gnc:html-chart-set-type! chart 'pie)
(gnc:html-chart-set-currency-iso!
diff --git a/gnucash/report/reports/standard/category-barchart.scm b/gnucash/report/reports/standard/category-barchart.scm
index d12a5819af..42971beb36 100644
--- a/gnucash/report/reports/standard/category-barchart.scm
+++ b/gnucash/report/reports/standard/category-barchart.scm
@@ -263,9 +263,6 @@ developing over time"))
(gnc-account-get-children-sorted
(gnc-get-current-root-account)))))
- ;; apply default settings from preferences
- (gnc:html-chart-apply-preferences-report! chart)
-
;; Returns true if the account a was selected in the account
;; selection option.
(define (show-acct? a)
@@ -528,6 +525,9 @@ Please deselect the accounts with negative balances."))
(list-of-rows #f)
(row-totals #f))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
;; Set chart title, subtitle etc.
(gnc:html-chart-set-type!
chart (if (eq? chart-type 'barchart) 'bar 'line))
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index 1f3f37897a..d6d2cb7d40 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -210,9 +210,6 @@
(document (gnc:make-html-document))
(chart (gnc:make-html-chart)))
- ;; apply default settings from preferences
- (gnc:html-chart-apply-preferences-report! chart)
-
;; This exchanges the commodity-collector 'c' to one single
;; 'report-currency' according to the exchange-fn. Returns an
;; amount.
@@ -315,6 +312,8 @@
(date-string-list (map qof-print-date dates-list)))
(gnc:report-percent-done 90)
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
(gnc:html-chart-set-type! chart (if linechart? 'line 'bar))
(gnc:html-chart-set-width! chart width)
diff --git a/gnucash/report/reports/standard/price-scatter.scm b/gnucash/report/reports/standard/price-scatter.scm
index 3e041d98e7..b3cb41b0b7 100644
--- a/gnucash/report/reports/standard/price-scatter.scm
+++ b/gnucash/report/reports/standard/price-scatter.scm
@@ -155,9 +155,6 @@
(int-secs (cadr (assq-ref intervals interval)))
(data '()))
- ;; apply default settings from preferences
- (gnc:html-chart-apply-preferences-report! chart)
-
;; Short helper for all the warnings below
(define (make-warning title text)
(gnc:html-document-add-object!
@@ -166,6 +163,9 @@
(gnc:html-markup-h3 title)
(gnc:html-markup-p text))))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
(gnc:html-chart-set-type! chart 'line)
(gnc:html-chart-set-currency-iso!
commit f5f133e104411a2cbe02878cb869aac0a68b4cba
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Sun Aug 23 15:26:10 2026 +0200
Enhancement - New global properties for CHARTS (GC's level)
This one a is quite an improvement on customisation of reports/charts. User can decide now what kind of point style should be used, including size, hover range and such.
On top of that:
- some tooltip improvements were made as well, including configurable one in GC's Properties.
- Price Scatterplot - fixed colors, got rid of a superfluous markers
- global defaults to be tuned in the next batch
Settings available at: GnuCash -> Edit -> Preferences -> Reports
diff --git a/gnucash/gnome-utils/dialog-preferences.c b/gnucash/gnome-utils/dialog-preferences.c
index c7a8d0b27e..e369aab5fd 100644
--- a/gnucash/gnome-utils/dialog-preferences.c
+++ b/gnucash/gnome-utils/dialog-preferences.c
@@ -1359,6 +1359,12 @@ gnc_preferences_dialog_create (GtkWindow *parent)
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "save_on_close_adj");
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "date_backmonth_adj");
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_zoom_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_chart_point_style_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_chart_point_size_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_chart_point_size_hover_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_chart_tooltip_engage_radius_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "default_chart_caret_size_adj");
+ gnc_builder_add_from_file (builder, "dialog-preferences.glade", "chart_point_style_list");
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "max_transactions_adj");
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "key_length_adj");
gnc_builder_add_from_file (builder, "dialog-preferences.glade", "new_search_limit_adj");
diff --git a/gnucash/gschemas/org.gnucash.GnuCash.gschema.xml.in b/gnucash/gschemas/org.gnucash.GnuCash.gschema.xml.in
index 3d32c99b5a..495f8200db 100644
--- a/gnucash/gschemas/org.gnucash.GnuCash.gschema.xml.in
+++ b/gnucash/gschemas/org.gnucash.GnuCash.gschema.xml.in
@@ -349,6 +349,11 @@
</key>
</schema>
+ <enum id="org.gnucash.GnuCash.general.report.TooltipPosition">
+ <value nick="average" value="0"/>
+ <value nick="nearest" value="1"/>
+ </enum>
+
<schema id="org.gnucash.GnuCash.general.report" path="/org/gnucash/GnuCash/general/report/">
<key name="use-new-window" type="b">
<default>false</default>
@@ -377,6 +382,36 @@
This option allows you to scale reports up by the set factor.
For example setting this to 2.0 will display reports at twice their typical size.</description>
</key>
+ <key name="chart-point-style" type="i">
+ <default>7</default>
+ <summary>A chart's point style.</summary>
+ <description>This setting specifies what kind of a point style should charts use. In previous versions it was always the circle, as of now it is confiugrable to chose among varius rectangles, triangles, and such. Only applicable to line charts.</description>
+ </key>
+ <key name="chart-point-size" type="i">
+ <default>4</default>
+ <summary>A chart's point size.</summary>
+ <description>This setting specifies the default point's size (in pixels) displayed in charts. Only applicable to line charts.</description>
+ </key>
+ <key name="chart-point-size-hover" type="i">
+ <default>9</default>
+ <summary>A chart's hovered-point size.</summary>
+ <description>This setting specifies the hovered point's size (in pixels) displayed in charts. It tends to be bigger than the default (i.e. not hovered over) size. Only applicable to line charts.</description>
+ </key>
+ <key name="chart-tooltip-engage-radius" type="i">
+ <default>7</default>
+ <summary>A hover radius that would engage a tooltip.</summary>
+ <description>This setting specifies the point's hover radius (in pixels) which translates into the proximity of which the point / tooltip will be engaged. If set to zero, the user must precisely aim at that point.</description>
+ </key>
+ <key name="chart-tooltip-caret-size" type="i">
+ <default>10</default>
+ <summary>An arrow size (caret) coming out of a tooltip's body.</summary>
+ <description>This setting specifies the size (in pixels) of an arrow (caret) that extends from a tooltip's body toward the data point. On a regular basis, a very small value - this setting's default has increased it significantly.</description>
+ </key>
+ <key name="chart-tooltip-position" enum="org.gnucash.GnuCash.general.report.TooltipPosition">
+ <default>'nearest'</default>
+ <summary>"Jump" behaviour when there are multiple splits</summary>
+ <description>Select how the "Jump" operation should behave when a transaction has multiple splits.</description>
+ </key>
<child name="pdf-export" schema="org.gnucash.GnuCash.general.report.pdf-export"/>
</schema>
<schema id="org.gnucash.GnuCash.general.report.pdf-export" path="/org/gnucash/GnuCash/general/report/pdf-export/">
diff --git a/gnucash/gtkbuilder/dialog-preferences.glade b/gnucash/gtkbuilder/dialog-preferences.glade
index 9858b1edfe..a080a0d09a 100644
--- a/gnucash/gtkbuilder/dialog-preferences.glade
+++ b/gnucash/gtkbuilder/dialog-preferences.glade
@@ -120,6 +120,71 @@
<property name="step-increment">1</property>
<property name="page-increment">10</property>
</object>
+ <object class="GtkAdjustment" id="default_chart_point_size_adj">
+ <property name="lower">1</property>
+ <property name="upper">25</property>
+ <property name="value">4</property>
+ <property name="step-increment">1</property>
+ <property name="page-increment">3</property>
+ </object>
+ <object class="GtkAdjustment" id="default_chart_point_size_hover_adj">
+ <property name="lower">1</property>
+ <property name="upper">50</property>
+ <property name="value">9</property>
+ <property name="step-increment">1</property>
+ <property name="page-increment">3</property>
+ </object>
+ <object class="GtkAdjustment" id="default_chart_tooltip_engage_radius_adj">
+ <property name="lower">1</property>
+ <property name="upper">100</property>
+ <property name="value">7</property>
+ <property name="step-increment">1</property>
+ <property name="page-increment">3</property>
+ </object>
+ <object class="GtkAdjustment" id="default_chart_caret_size_adj">
+ <property name="lower">1</property>
+ <property name="upper">50</property>
+ <property name="value">10</property>
+ <property name="step-increment">1</property>
+ <property name="page-increment">3</property>
+ </object>
+ <object class="GtkListStore" id="chart_point_style_list">
+ <columns>
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Circle</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Cross</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Cross - rotated</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Dash</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Line</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Rectangle</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Rectangle - rounded</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Rectangle - rotated</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Star</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Triangle</col>
+ </row>
+ </data>
+ </object>
<object class="GtkDialog" id="separator_validation_dialog">
<property name="can-focus">False</property>
<property name="modal">True</property>
@@ -3400,6 +3465,253 @@ many months before the current month</property>
<property name="top-attach">8</property>
</packing>
</child>
+ <child>
+ <object class="GtkLabel" id="label-tc-sep">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">9</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label-tc-1">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Line Charts</property>
+ <style>
+ <class name="gnc-class-strong"/>
+ </style>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">10</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Point style</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">11</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="pref/general.report/chart-point-style">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="has-tooltip">True</property>
+ <property name="tooltip-markup">Chart Point Style</property>
+ <property name="tooltip-text" translatable="yes">Which style should represent a data point. Only applicable to line charts. </property>
+ <property name="model">chart_point_style_list</property>
+ <property name="active">7</property>
+ <child>
+ <object class="GtkCellRendererText" id="tc-point-style-renderer"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">11</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Point size</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">12</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="pref/general.report/chart-point-size">
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="tooltip-text" translatable="yes">This setting specifies the default point's size (in pixels) displayed in charts. Only applicable to line charts.</property>
+ <property name="halign">start</property>
+ <property name="text">1</property>
+ <property name="adjustment">default_chart_point_size_adj</property>
+ <property name="digits">0</property>
+ <property name="value">1</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">12</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Point hovered size</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">13</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="pref/general.report/chart-point-size-hover">
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="tooltip-text" translatable="yes">This setting specifies the hovered point's size (in pixels) displayed in charts. It tends to be bigger than the default (i.e. not hovered over) size. Only applicable to line charts.</property>
+ <property name="halign">start</property>
+ <property name="text">1</property>
+ <property name="adjustment">default_chart_point_size_hover_adj</property>
+ <property name="digits">0</property>
+ <property name="value">1</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">13</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label-tc-sep2">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">14</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label-tc-2">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Tooltip</property>
+ <style>
+ <class name="gnc-class-strong"/>
+ </style>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">15</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Engage within this radius</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">16</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="pref/general.report/chart-tooltip-engage-radius">
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="tooltip-text" translatable="yes">This setting specifies the point's hover radius (in pixels) which translates into the proximity of which the point / tooltip will be engaged. If set to zero, the user must precisely aim at that point.</property>
+ <property name="halign">start</property>
+ <property name="text">1</property>
+ <property name="adjustment">default_chart_tooltip_engage_radius_adj</property>
+ <property name="digits">0</property>
+ <property name="value">1</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">16</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Pointing arrow (caret) size</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">17</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="pref/general.report/chart-tooltip-caret-size">
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="tooltip-text" translatable="yes">This setting specifies the size (in pixels) of an arrow (caret) that extends from a tooltip's body toward the data point. On a regular basis, a very small value - this setting's default has increased it significantly.</property>
+ <property name="halign">start</property>
+ <property name="text">1</property>
+ <property name="adjustment">default_chart_caret_size_adj</property>
+ <property name="digits">0</property>
+ <property name="value">1</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">17</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Position (for grouped only)</property>
+ </object>
+ <packing>
+ <property name="left-attach">0</property>
+ <property name="top-attach">18</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="pref/general.report/chart-tooltip-position=average">
+ <property name="label" translatable="yes">average</property>
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="receives-default">False</property>
+ <property name="has-tooltip">True</property>
+ <property name="tooltip-markup">Show tooltip at the AVERAGE value (i.e. in between) of engaged entry/entries. Only applicable to the grouped/indexed type of a tooltip.</property>
+ <property name="tooltip-text" translatable="yes">Show tooltip at the AVERAGE value (i.e. in between) of engaged entry/entries. Only applicable to the grouped/indexed type of a tooltip.</property>
+ <property name="halign">start</property>
+ <property name="use-underline">True</property>
+ <property name="active">True</property>
+ <property name="draw-indicator">True</property>
+ <property name="group">pref/general.report/chart-tooltip-position=nearest</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">18</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="pref/general.report/chart-tooltip-position=nearest">
+ <property name="label" translatable="yes">nearest</property>
+ <property name="visible">True</property>
+ <property name="can-focus">True</property>
+ <property name="receives-default">False</property>
+ <property name="has-tooltip">True</property>
+ <property name="tooltip-markup">Show tooltip NEAREST to value of engaged entry/entries. Only applicable to the grouped/indexed type of a tooltip.</property>
+ <property name="tooltip-text" translatable="yes">Show tooltip NEAREST to value of engaged entry/entries. Only applicable to the grouped/indexed type of a tooltip.</property>
+ <property name="halign">start</property>
+ <property name="use-underline">True</property>
+ <property name="active">True</property>
+ <property name="draw-indicator">True</property>
+ <property name="group">pref/general.report/chart-tooltip-position=nearest</property>
+ </object>
+ <packing>
+ <property name="left-attach">1</property>
+ <property name="top-attach">19</property>
+ </packing>
+ </child>
<child>
<placeholder/>
</child>
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index fb1f7d4e96..f5d202f852 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -69,6 +69,7 @@
(export gnc:html-chart-set-grid?!)
(export gnc:html-chart-set-y-axis-label!)
(export gnc:html-chart-add-data-series!)
+(export gnc:html-chart-apply-preferences-report!)
(define gnc:showTooltipNonZerOnly #f)
@@ -214,7 +215,9 @@
(cons 'line (list
(cons 'tension 0)))
(cons 'point (list
- (cons 'pointStyle #f)))))
+ (cons 'pointStyle #f)
+ (cons 'hoverBorderColor 'black)
+ (cons 'hoverBorderWidth 1)))))
(cons 'tooltips (list
(cons 'mode 'index)
(cons 'intersect #f)
@@ -303,6 +306,30 @@
(define (gnc:html-chart-set-tooltip-non-zero-only! chart nonZeroOnly)
(gnc:html-chart-set! chart '(options tooltips showNonZeroOnly) nonZeroOnly))
+(define (gnc:html-chart-apply-preferences-report! chart)
+ (gnc:html-chart-set! chart '(options elements point pointStyle)
+ (case (gnc-prefs-get-int "general.report" "chart-point-style")
+ ((0) "circle") ((1) "cross") ((2) "crossRot")
+ ((3) "dash") ((4) "line") ((5) "rect")
+ ((6) "rectRounded") ((7) "rectRot") ((8) "star")
+ ((9) "triangle") (else "circle")))
+
+ (gnc:html-chart-set! chart '(options elements point radius)
+ (gnc-prefs-get-int "general.report" "chart-point-size"))
+
+ (gnc:html-chart-set! chart '(options elements point hoverRadius)
+ (gnc-prefs-get-int "general.report" "chart-point-size-hover"))
+
+ (gnc:html-chart-set! chart '(options elements point hitRadius)
+ (gnc-prefs-get-int "general.report" "chart-tooltip-engage-radius"))
+
+ (gnc:html-chart-set! chart '(options tooltips caretSize)
+ (gnc-prefs-get-int "general.report" "chart-tooltip-caret-size"))
+
+ (gnc:html-chart-set! chart '(options tooltips position)
+ (gnc-prefs-get-string "general.report" "chart-tooltip-position"))
+)
+
;; e.g.:
;; (gnc:html-chart-add-data-series! chart "label" list-of-numbers color
;; 'fill #t
diff --git a/gnucash/report/reports/standard/account-piecharts.scm b/gnucash/report/reports/standard/account-piecharts.scm
index 912fb6d300..d5c95869a4 100644
--- a/gnucash/report/reports/standard/account-piecharts.scm
+++ b/gnucash/report/reports/standard/account-piecharts.scm
@@ -339,6 +339,9 @@ balance at a given time"))
(gnc-account-get-children-sorted
(gnc-get-current-root-account)))))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
;; Returns true if the account a was selected in the account
;; selection option.
(define (show-acct? a)
diff --git a/gnucash/report/reports/standard/category-barchart.scm b/gnucash/report/reports/standard/category-barchart.scm
index 59c73f6aa9..d12a5819af 100644
--- a/gnucash/report/reports/standard/category-barchart.scm
+++ b/gnucash/report/reports/standard/category-barchart.scm
@@ -263,6 +263,9 @@ developing over time"))
(gnc-account-get-children-sorted
(gnc-get-current-root-account)))))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
;; Returns true if the account a was selected in the account
;; selection option.
(define (show-acct? a)
@@ -540,6 +543,19 @@ Please deselect the accounts with negative balances."))
(gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
(gnc:html-chart-set-tooltip-non-zero-only! chart (get-option gnc:pagename-display optname-tooltip-non-zero-only))
+ ;; tailor applied GC's preferences toward this particular chart
+ (let ((isAverage (string=? (gnc-prefs-get-string "general.report" "chart-tooltip-position") "average"))
+ (pointSize (gnc-prefs-get-int "general.report" "chart-point-size"))
+ (pointSizeH (gnc-prefs-get-int "general.report" "chart-point-size-hover"))
+ (isLineChart (if (eq? chart-type 'linechart) #t #f))
+ )(
+ if (or (not isLineChart) (and tooltip-indexed isAverage isLineChart))
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) 0)
+ (if tooltip-indexed
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) (+ pointSize 2))
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) (+ pointSizeH 2))
+ )))
+
(gnc:html-chart-set-data-labels! chart date-string-list)
(gnc:html-chart-set-y-axis-label!
chart (if ratio-chart? "Ratio"
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index b1464e02bc..1f3f37897a 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -56,8 +56,6 @@
(define optname-line-width (N_ "Line Width"))
(define opthelp-line-width (N_ "Set line width in pixels."))
-(define optname-markers (N_ "Data markers?"))
-
(define optname-tooltip-indexed (N_ "Show a grouped (indexed) tooltip"))
(define optname-tooltip-non-zero-only (N_ "Show only non-zero values in a tooltip"))
@@ -143,12 +141,7 @@
;; gnc:pagename-display optname-x-grid
;; "g" (N_ "Add vertical grid lines.")
;; #f))
-
- (gnc-register-simple-boolean-option options
- gnc:pagename-display optname-markers
- "g" (N_ "Display a mark for each data point.")
- #t)
- ))
+ ))
(gnc-register-simple-boolean-option options
gnc:pagename-display optname-tooltip-indexed
@@ -198,8 +191,6 @@
(tooltip-indexed (get-option gnc:pagename-display optname-tooltip-indexed))
(height (get-option gnc:pagename-display optname-plot-height))
(width (get-option gnc:pagename-display optname-plot-width))
- (markers (and linechart?
- (if (get-option gnc:pagename-display optname-markers) 3 0)))
(line-width (and linechart?
(get-option gnc:pagename-display optname-line-width)))
(y-grid (or (not linechart?) (get-option gnc:pagename-display optname-y-grid)))
@@ -219,6 +210,9 @@
(document (gnc:make-html-document))
(chart (gnc:make-html-chart)))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
;; This exchanges the commodity-collector 'c' to one single
;; 'report-currency' according to the exchange-fn. Returns an
;; amount.
@@ -330,6 +324,18 @@
(gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
(gnc:html-chart-set-tooltip-non-zero-only! chart (get-option gnc:pagename-display optname-tooltip-non-zero-only))
+ ;; tailor applied GC's preferences toward this particular chart
+ (let ((isAverage (string=? (gnc-prefs-get-string "general.report" "chart-tooltip-position") "average"))
+ (pointSize (gnc-prefs-get-int "general.report" "chart-point-size"))
+ (pointSizeH (gnc-prefs-get-int "general.report" "chart-point-size-hover"))
+ )(
+ if (or (not linechart?) (and tooltip-indexed isAverage linechart?))
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) 0)
+ (if tooltip-indexed
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) (+ pointSize 2))
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) (+ pointSizeH 2))
+ )))
+
(gnc:html-chart-set-y-axis-label!
chart (gnc-commodity-get-mnemonic report-currency))
(gnc:html-chart-set-grid?! chart y-grid)
@@ -347,7 +353,6 @@
minuend-balances
"#0074D9"
'fill (not linechart?)
- 'pointRadius markers
'borderWidth line-width
'urls (gnc:make-report-anchor
(if inc-exp?
@@ -368,7 +373,6 @@
(map - subtrahend-balances)
"#FF4136"
'fill (not linechart?)
- 'pointRadius markers
'borderWidth line-width
'urls (gnc:make-report-anchor
(if inc-exp?
@@ -390,7 +394,6 @@
difference-balances
"#2ECC40"
'fill (not linechart?)
- 'pointRadius markers
'borderWidth line-width))
;; Test for all-zero data here.
diff --git a/gnucash/report/reports/standard/price-scatter.scm b/gnucash/report/reports/standard/price-scatter.scm
index 370004bb91..3e041d98e7 100644
--- a/gnucash/report/reports/standard/price-scatter.scm
+++ b/gnucash/report/reports/standard/price-scatter.scm
@@ -43,7 +43,6 @@
(define optname-price-source (N_ "Price Source"))
(define optname-invert (N_ "Invert prices"))
-(define optname-marker (N_ "Marker"))
(define optname-markercolor (N_ "Marker Color"))
(define optname-plot-width (N_ "Plot Width"))
(define optname-plot-height (N_ "Plot Height"))
@@ -85,10 +84,6 @@
(gnc:options-add-plot-size!
options gnc:pagename-display
optname-plot-width optname-plot-height "c" (cons 'percent 100.0) (cons 'percent 100.0))
-
- (gnc:options-add-marker-choice!
- options gnc:pagename-display
- optname-marker "a" 'filledsquare)
(gnc-register-color-option options
gnc:pagename-display optname-markercolor
@@ -131,7 +126,6 @@
(height (get-option gnc:pagename-display optname-plot-height))
(width (get-option gnc:pagename-display optname-plot-width))
- (marker (get-option gnc:pagename-display optname-marker))
(mcolor
(gnc:color-option->hex-string
(gnc:lookup-option (gnc:report-options report-obj)
@@ -161,6 +155,9 @@
(int-secs (cadr (assq-ref intervals interval)))
(data '()))
+ ;; apply default settings from preferences
+ (gnc:html-chart-apply-preferences-report! chart)
+
;; Short helper for all the warnings below
(define (make-warning title text)
(gnc:html-document-add-object!
@@ -185,16 +182,6 @@
(gnc-date-interval-format from-date to-date))))
(gnc:html-chart-set-width! chart width)
(gnc:html-chart-set-height! chart height)
- (gnc:html-chart-set! chart
- '(options elements point pointStyle)
- (case marker
- ((filleddiamond diamond) "rectRot")
- ((filledcircle circle) "circle")
- ((filledsquare square) "rect")
- ((cross) "crossRot")
- ((plus) "cross")
- ((dash) "line")))
-
(gnc:html-chart-set-y-axis-label!
chart (gnc-commodity-get-mnemonic amount-commodity))
@@ -202,6 +189,9 @@
(gnc:html-chart-set-x-axis-type! chart 'linear)
(gnc:html-chart-set-custom-x-axis-ticks?! chart #f)
+ ;; tailor applied GC's preferences toward this particular chart
+ (gnc:html-chart-set! chart '(options tooltips caretPadding) (+ (gnc-prefs-get-int "general.report" "chart-point-size") 2))
+
(cond
((gnc-commodity-equiv report-currency price-commodity)
(make-warning
@@ -273,7 +263,7 @@ Unfortunately, the plotting tool can't handle that.")))
chart (map
(match-lambda
((x y)
- (format #f "~2,2f ~a = ~a"
+ (format #f "~2,2F ~a = ~a"
x int-label (gnc:monetary->string
(gnc:make-gnc-monetary amount-commodity y)))))
data))
@@ -281,10 +271,9 @@ Unfortunately, the plotting tool can't handle that.")))
(gnc:html-chart-add-data-series!
chart (G_ "Price")
(map (match-lambda ((x y) (list (cons 'x x) (cons 'y y)))) data)
- mcolor
- 'pointBorderColor mcolor 'fill #f 'borderColor "#4bb2c5"
- 'pointBackgroundColor
- (if (memq marker '(filledcircle filledsquare filleddiamond)) mcolor "white"))
+ (string-append "#" mcolor)
+ 'pointBorderColor (string-append "#" mcolor) 'fill #f 'borderColor "#4bb2c5"
+ 'pointBackgroundColor (string-append "#" mcolor))
(gnc:html-document-add-object! document chart)))))
@@ -293,7 +282,7 @@ Unfortunately, the plotting tool can't handle that.")))
;; Here we define the actual report
(gnc:define-report
'version 1
- 'name (N_ "Price")
+ 'name (N_ "Price Scatterplot")
'report-guid "1d241609fd4644caad765c95be20ff4c"
'menu-path (list gnc:menuname-asset-liability)
'menu-name (N_ "Price Scatterplot")
diff --git a/libgnucash/core-utils/gnc-prefs.h b/libgnucash/core-utils/gnc-prefs.h
index 00549dd2e8..698dbbd162 100644
--- a/libgnucash/core-utils/gnc-prefs.h
+++ b/libgnucash/core-utils/gnc-prefs.h
@@ -93,6 +93,13 @@
#define GNC_PREF_CURRENCY_OTHER "currency-other"
#define GNC_PREF_CURRENCY_CHOICE_LOCALE "currency-choice-locale"
#define GNC_PREF_CURRENCY_CHOICE_OTHER "currency-choice-other"
+/* Chart preferences */
+#define GNC_CHART_POINT_STYLE "chart-point-style"
+#define GNC_CHART_POINT_SIZE "chart-point-size"
+#define GNC_CHART_POINT_SIZE_HOVER "chart-point-size-hover"
+#define GNC_CHART_TOOLTIP_CARET "chart-tooltip-caret-size"
+#define GNC_CHART_TOOLTIP_POSITION "chart-tooltip-position"
+#define GNC_CHART_TOOLTIP_ENGAGE_RADIUS "chart-tooltip-engage-radius"
#ifdef __cplusplus
extern "C" {
commit 284e7434ce6413d7a5a937d394b93f653ee3567a
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Sun Aug 23 14:53:55 2026 +0200
Enhancement - tooltip - a non-zero-values filter
A switchable option (per chart) that enganges filter to show non-zero values only. Default: turned on.
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index b4b7acff78..fb1f7d4e96 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -56,6 +56,7 @@
(export gnc:html-chart-set-format-style!)
(export gnc:html-chart-render)
(export gnc:html-chart-set-tooltip-indexed?!)
+(export gnc:html-chart-set-tooltip-non-zero-only!)
(export gnc:html-chart-set-custom-x-axis-ticks?!)
(export gnc:html-chart-set-title!)
(export gnc:html-chart-set-data-labels!)
@@ -69,6 +70,8 @@
(export gnc:html-chart-set-y-axis-label!)
(export gnc:html-chart-add-data-series!)
+(define gnc:showTooltipNonZerOnly #f)
+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; utility functions for nested list handling
@@ -297,6 +300,9 @@
(gnc:html-chart-set! chart '(options tooltips mode) 'point)
))
+(define (gnc:html-chart-set-tooltip-non-zero-only! chart nonZeroOnly)
+ (gnc:html-chart-set! chart '(options tooltips showNonZeroOnly) nonZeroOnly))
+
;; e.g.:
;; (gnc:html-chart-add-data-series! chart "label" list-of-numbers color
;; 'fill #t
@@ -388,7 +394,15 @@ function tooltipLabel(tooltipItem,data) {
}
function tooltipTitle(array,data) {
- return data.labels[array[0].index]; }
+ if (!data || array.length === 0) {
+ return '';
+ }
+ return data.labels[array[0].index];
+}
+
+function tooltipFilter(tooltipItem, data) {
+ return tooltipItem.yLabel != 0;
+}
// draw the background color
Chart.pluginService.register({
@@ -498,6 +512,7 @@ document.getElementById(chartid).onclick = function(evt) {
(push "chartjsoptions.options.tooltips.callbacks.label = tooltipLabel;\n")
(push "chartjsoptions.options.tooltips.callbacks.title = tooltipTitle;\n")
+ (push "if (chartjsoptions.options.tooltips.showNonZeroOnly) { chartjsoptions.options.tooltips.filter = tooltipFilter; }\n")
(push JS-setup)
(push "var myChart = new Chart(chartid, chartjsoptions);\n")
diff --git a/gnucash/report/reports/standard/category-barchart.scm b/gnucash/report/reports/standard/category-barchart.scm
index 54e7b31448..59c73f6aa9 100644
--- a/gnucash/report/reports/standard/category-barchart.scm
+++ b/gnucash/report/reports/standard/category-barchart.scm
@@ -83,6 +83,7 @@ developing over time"))
(define optname-chart-type (N_ "Chart Type"))
(define optname-tooltip-indexed (N_ "Show a grouped (indexed) tooltip"))
+(define optname-tooltip-non-zero-only (N_ "Show only non-zero values in a tooltip"))
(define optname-stacked (N_ "Use Stacked Charts"))
(define optname-slices (N_ "Maximum Bars"))
@@ -188,6 +189,11 @@ developing over time"))
"t1" (N_ "Show all items, along the x-axis, in a grouped tooltip. Otherwise - only a single entry, as per coursor's nearest proximity.")
#f)
+ (gnc-register-simple-boolean-option options
+ gnc:pagename-display optname-tooltip-non-zero-only
+ "t2" (N_ "Show only non-zero values in a tooltip.")
+ #t)
+
(gnc:options-set-default-section options gnc:pagename-general)
options))
@@ -532,6 +538,7 @@ Please deselect the accounts with negative balances."))
(gnc:html-chart-set-height! chart height)
(gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
+ (gnc:html-chart-set-tooltip-non-zero-only! chart (get-option gnc:pagename-display optname-tooltip-non-zero-only))
(gnc:html-chart-set-data-labels! chart date-string-list)
(gnc:html-chart-set-y-axis-label!
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index 5199e11e3f..b1464e02bc 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -57,7 +57,9 @@
(define opthelp-line-width (N_ "Set line width in pixels."))
(define optname-markers (N_ "Data markers?"))
+
(define optname-tooltip-indexed (N_ "Show a grouped (indexed) tooltip"))
+(define optname-tooltip-non-zero-only (N_ "Show only non-zero values in a tooltip"))
;;(define optname-x-grid (N_ "X grid"))
(define optname-y-grid (N_ "Grid"))
@@ -153,6 +155,10 @@
"t1" (N_ "Show all items, along the x-axis, in a grouped tooltip. Otherwise - only a single entry, as per coursor's nearest proximity.")
#t)
+ (gnc-register-simple-boolean-option options
+ gnc:pagename-display optname-tooltip-non-zero-only
+ "t2" (N_ "Show only non-zero values in a tooltip.")
+ #t)
(gnc:options-set-default-section options gnc:pagename-general)
@@ -322,6 +328,8 @@
(gnc:html-chart-set-title!
chart (list report-title (gnc-date-interval-format from-date-t64 to-date-t64)))
(gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
+ (gnc:html-chart-set-tooltip-non-zero-only! chart (get-option gnc:pagename-display optname-tooltip-non-zero-only))
+
(gnc:html-chart-set-y-axis-label!
chart (gnc-commodity-get-mnemonic report-currency))
(gnc:html-chart-set-grid?! chart y-grid)
commit 43a01b3c48fc809982bf53a4e89597e0cbbe7d96
Author: PRG-112 <274233038+PRG-112 at users.noreply.github.com>
Date: Sun Aug 23 14:51:00 2026 +0200
Several fixes as per Christopher's input
- no more "nearest" mode as the default for INDEXED type
- better user-facing texts
- opened for another improvements that will come shortly
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index b7db7df5f9..b4b7acff78 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -292,7 +292,10 @@
(gnc:html-chart-set! chart '(options scales xAxes (0) type) type))
(define (gnc:html-chart-set-tooltip-indexed?! chart indexed?)
- (gnc:html-chart-set! chart '(options tooltips mode) (if indexed? 'index 'nearest)))
+ (if indexed?
+ (gnc:html-chart-set! chart '(options tooltips mode) 'index)
+ (gnc:html-chart-set! chart '(options tooltips mode) 'point)
+))
;; e.g.:
;; (gnc:html-chart-add-data-series! chart "label" list-of-numbers color
diff --git a/gnucash/report/reports/standard/category-barchart.scm b/gnucash/report/reports/standard/category-barchart.scm
index adba17e767..54e7b31448 100644
--- a/gnucash/report/reports/standard/category-barchart.scm
+++ b/gnucash/report/reports/standard/category-barchart.scm
@@ -82,7 +82,7 @@ developing over time"))
(define optname-fullname (N_ "Show long account names"))
(define optname-chart-type (N_ "Chart Type"))
-(define optname-tooltip-indexed (N_ "Show indexed tooltip"))
+(define optname-tooltip-indexed (N_ "Show a grouped (indexed) tooltip"))
(define optname-stacked (N_ "Use Stacked Charts"))
(define optname-slices (N_ "Maximum Bars"))
@@ -185,9 +185,8 @@ developing over time"))
(gnc-register-simple-boolean-option options
gnc:pagename-display optname-tooltip-indexed
- "h" (N_ "INDEX-ed tooltip presents all data from a selected date. NON-indexed - only a single one that is the closest to the coursor")
- #t)
-
+ "t1" (N_ "Show all items, along the x-axis, in a grouped tooltip. Otherwise - only a single entry, as per coursor's nearest proximity.")
+ #f)
(gnc:options-set-default-section options gnc:pagename-general)
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index 89f9c92527..5199e11e3f 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -57,7 +57,7 @@
(define opthelp-line-width (N_ "Set line width in pixels."))
(define optname-markers (N_ "Data markers?"))
-(define optname-tooltip-indexed (N_ "Show indexed tooltip?"))
+(define optname-tooltip-indexed (N_ "Show a grouped (indexed) tooltip"))
;;(define optname-x-grid (N_ "X grid"))
(define optname-y-grid (N_ "Grid"))
@@ -150,7 +150,7 @@
(gnc-register-simple-boolean-option options
gnc:pagename-display optname-tooltip-indexed
- "h" (N_ "Show all viable entries per time unit (indexed). Otherwise - only a single entry, as per coursor's exact position.")
+ "t1" (N_ "Show all items, along the x-axis, in a grouped tooltip. Otherwise - only a single entry, as per coursor's nearest proximity.")
#t)
commit cf01513973732ee0b10cf5cf73f61750bd7c7319
Author: PRG-112 <tt at pieroog.com>
Date: Wed Aug 5 16:49:09 2026 +0200
Better user-facing text.
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index 3d57d6ace0..89f9c92527 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -150,7 +150,7 @@
(gnc-register-simple-boolean-option options
gnc:pagename-display optname-tooltip-indexed
- "h" (N_ "INDEX-ed tooltip presents all data from a selected date. NON-indexed - only the one that is the closest to the coursor.")
+ "h" (N_ "Show all viable entries per time unit (indexed). Otherwise - only a single entry, as per coursor's exact position.")
#t)
commit a0608466829fa20a81ac94a1427a9fe99aef7e09
Author: PRG-112 <tt at pieroog.com>
Date: Tue Aug 4 12:21:12 2026 +0200
Enhancement 799798 - bringing back the previous tooltip (from 4.x) as a configurable choice (https://bugs.gnucash.org/show_bug.cgi?id=799798)
between versions 4 and 5, the GC team changed the default behavior of the tooltip, namely configured it toward an indexed one. The indexed tooltip is a collection of all values, in one sitting, per time unit. While it has plenty of use, it can get very messy with bigger data-sets. (see the screenshot)
My proposal rectifies the above by giving a user choice to decide which one should be used (the current way is still the default option). (see the screenshot)
>> Screenshots based on: GC Sample Database: https://github.com/PRG-112/gnucash-sample-db-generator
diff --git a/gnucash/report/html-chart.scm b/gnucash/report/html-chart.scm
index d8a8fdfa10..b7db7df5f9 100644
--- a/gnucash/report/html-chart.scm
+++ b/gnucash/report/html-chart.scm
@@ -55,6 +55,7 @@
(export gnc:html-chart-format-style)
(export gnc:html-chart-set-format-style!)
(export gnc:html-chart-render)
+(export gnc:html-chart-set-tooltip-indexed?!)
(export gnc:html-chart-set-custom-x-axis-ticks?!)
(export gnc:html-chart-set-title!)
(export gnc:html-chart-set-data-labels!)
@@ -290,6 +291,9 @@
(define (gnc:html-chart-set-x-axis-type! chart type)
(gnc:html-chart-set! chart '(options scales xAxes (0) type) type))
+(define (gnc:html-chart-set-tooltip-indexed?! chart indexed?)
+ (gnc:html-chart-set! chart '(options tooltips mode) (if indexed? 'index 'nearest)))
+
;; e.g.:
;; (gnc:html-chart-add-data-series! chart "label" list-of-numbers color
;; 'fill #t
diff --git a/gnucash/report/reports/standard/category-barchart.scm b/gnucash/report/reports/standard/category-barchart.scm
index ee63e271a3..adba17e767 100644
--- a/gnucash/report/reports/standard/category-barchart.scm
+++ b/gnucash/report/reports/standard/category-barchart.scm
@@ -82,6 +82,7 @@ developing over time"))
(define optname-fullname (N_ "Show long account names"))
(define optname-chart-type (N_ "Chart Type"))
+(define optname-tooltip-indexed (N_ "Show indexed tooltip"))
(define optname-stacked (N_ "Use Stacked Charts"))
(define optname-slices (N_ "Maximum Bars"))
@@ -182,6 +183,12 @@ developing over time"))
options gnc:pagename-display
optname-sort-method "g" 'amount)
+ (gnc-register-simple-boolean-option options
+ gnc:pagename-display optname-tooltip-indexed
+ "h" (N_ "INDEX-ed tooltip presents all data from a selected date. NON-indexed - only a single one that is the closest to the coursor")
+ #t)
+
+
(gnc:options-set-default-section options gnc:pagename-general)
options))
@@ -237,6 +244,7 @@ developing over time"))
(height (get-option gnc:pagename-display optname-plot-height))
(width (get-option gnc:pagename-display optname-plot-width))
(sort-method (get-option gnc:pagename-display optname-sort-method))
+ (tooltip-indexed (get-option gnc:pagename-display optname-tooltip-indexed))
(work-done 0)
(work-to-do 0)
@@ -524,6 +532,8 @@ Please deselect the accounts with negative balances."))
(gnc:html-chart-set-width! chart width)
(gnc:html-chart-set-height! chart height)
+ (gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
+
(gnc:html-chart-set-data-labels! chart date-string-list)
(gnc:html-chart-set-y-axis-label!
chart (if ratio-chart? "Ratio"
diff --git a/gnucash/report/reports/standard/net-charts.scm b/gnucash/report/reports/standard/net-charts.scm
index d3695c750a..3d57d6ace0 100644
--- a/gnucash/report/reports/standard/net-charts.scm
+++ b/gnucash/report/reports/standard/net-charts.scm
@@ -57,6 +57,7 @@
(define opthelp-line-width (N_ "Set line width in pixels."))
(define optname-markers (N_ "Data markers?"))
+(define optname-tooltip-indexed (N_ "Show indexed tooltip?"))
;;(define optname-x-grid (N_ "X grid"))
(define optname-y-grid (N_ "Grid"))
@@ -147,6 +148,12 @@
#t)
))
+ (gnc-register-simple-boolean-option options
+ gnc:pagename-display optname-tooltip-indexed
+ "h" (N_ "INDEX-ed tooltip presents all data from a selected date. NON-indexed - only the one that is the closest to the coursor.")
+ #t)
+
+
(gnc:options-set-default-section options gnc:pagename-general)
options))
@@ -182,6 +189,7 @@
(show-net? (get-option gnc:pagename-display (if inc-exp?
optname-show-profit
optname-net-bars)))
+ (tooltip-indexed (get-option gnc:pagename-display optname-tooltip-indexed))
(height (get-option gnc:pagename-display optname-plot-height))
(width (get-option gnc:pagename-display optname-plot-width))
(markers (and linechart?
@@ -313,6 +321,7 @@
(gnc:html-chart-set-height! chart height)
(gnc:html-chart-set-title!
chart (list report-title (gnc-date-interval-format from-date-t64 to-date-t64)))
+ (gnc:html-chart-set-tooltip-indexed?! chart tooltip-indexed)
(gnc:html-chart-set-y-axis-label!
chart (gnc-commodity-get-mnemonic report-currency))
(gnc:html-chart-set-grid?! chart y-grid)
commit 075ab5690f7712673c3b7880e729f541166cb5a0
Merge: 9b85edef2e a001e3e089
Author: John Ralls <jralls at ceridwen.us>
Date: Sun Aug 30 15:01:14 2026 -0700
Merge Christian Wehling's 'HBCI' into stable
commit a001e3e089c5d40d5e47397ec0a841a5c205a67d
Author: Christian Wehling <christian.wehling at web.de>
Date: Wed Jan 17 20:56:49 2024 +0100
HBCI is a subtype of FinTS, therefore some text passages have to be
adjusted.
diff --git a/gnucash/gnome/gnucash.appdata.xml.in.in b/gnucash/gnome/gnucash.appdata.xml.in.in
index de76d93661..0930ef6536 100644
--- a/gnucash/gnome/gnucash.appdata.xml.in.in
+++ b/gnucash/gnome/gnucash.appdata.xml.in.in
@@ -15,14 +15,16 @@
</p>
<p>With GnuCash you can (but are not limited to):</p>
<ul>
- <li>Keep track of your day to day personal income and expenses</li>
- <li>Manage your stock, bond and mutual fund accounts with ease</li>
- <li>Keep your small business' accounting up to date</li>
- <li>Create accurate reports and graphs from your financial data</li>
- <li>Set up scheduled transactions to avoid repeated data entry</li>
- <li>Exchange by CSV/FinTS(former HBCI) or import SWIFT-MT9xx/QIF/OFX data
- including Transaction Matching</li>
- <li>Perform financial calculations, such as a loan repayment</li>
+ <li>Keep track of your day to day personal income and expenses.</li>
+ <li>Manage your stock, bond and mutual fund accounts with ease.</li>
+ <li>Keep your small business' accounting up to date.</li>
+ <li>Create accurate reports and graphs from your financial data.</li>
+ <li>Set up scheduled transactions to avoid repeated data entry.</li>
+ <li>Process your bank data via online banking using FinTS.</li>
+ <li>Download Transactions and Balances and initiate various SEPA Actions using AqBanking.</li>
+ <li>Import accounts, business data, prices, and transactions from CSV and transactions and balances from many formats including CAMT, SWIFT-MT9xx, and OFX.</li>
+ <li>Export the account tree or transactions as CSV.</li>
+ <li>Perform financial calculations, such as a loan repayment.</li>
</ul>
</description>
diff --git a/gnucash/import-export/aqb/dialog-ab-pref.glade b/gnucash/import-export/aqb/dialog-ab-pref.glade
index 62ceb791ab..f6b88a968f 100644
--- a/gnucash/import-export/aqb/dialog-ab-pref.glade
+++ b/gnucash/import-export/aqb/dialog-ab-pref.glade
@@ -36,8 +36,8 @@
<property name="can-focus">True</property>
<property name="receives-default">False</property>
<property name="has-tooltip">True</property>
- <property name="tooltip-markup">If active, the window will be closed automatically when you finish the HBCI/AqBanking import process. Otherwise it will stay open.</property>
- <property name="tooltip-text" translatable="yes">If active, the window will be closed automatically when you finish the HBCI/AqBanking import process. Otherwise it will stay open.</property>
+ <property name="tooltip-markup">If active, the window will be closed automatically when you finish the AqBanking import process. Otherwise it will stay open.</property>
+ <property name="tooltip-text" translatable="yes">If active, the window will be closed automatically when you finish the AqBanking import process. Otherwise it will stay open.</property>
<property name="halign">start</property>
<property name="use-underline">True</property>
<property name="draw-indicator">True</property>
@@ -54,8 +54,8 @@
<property name="can-focus">True</property>
<property name="receives-default">False</property>
<property name="has-tooltip">True</property>
- <property name="tooltip-markup">If active, the PIN for HBCI/AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</property>
- <property name="tooltip-text" translatable="yes">If active, the PIN for HBCI/AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</property>
+ <property name="tooltip-markup">If active, the PIN for AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</property>
+ <property name="tooltip-text" translatable="yes">If active, the PIN for AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</property>
<property name="halign">start</property>
<property name="use-underline">True</property>
<property name="draw-indicator">True</property>
@@ -90,8 +90,8 @@
<property name="can-focus">True</property>
<property name="receives-default">False</property>
<property name="has-tooltip">True</property>
- <property name="tooltip-markup">Enables verbose debug messages for HBCI/AqBanking Online Banking.</property>
- <property name="tooltip-text" translatable="yes">Enables verbose debug messages for HBCI/AqBanking Online Banking.</property>
+ <property name="tooltip-markup">Enables verbose debug messages for AqBanking.</property>
+ <property name="tooltip-text" translatable="yes">Enables verbose debug messages for AqBanking. See the Wiki for more information.</property>
<property name="halign">start</property>
<property name="use-underline">True</property>
<property name="draw-indicator">True</property>
diff --git a/gnucash/import-export/aqb/gnc-ab-utils.c b/gnucash/import-export/aqb/gnc-ab-utils.c
index 6802135748..5b69f36280 100644
--- a/gnucash/import-export/aqb/gnc-ab-utils.c
+++ b/gnucash/import-export/aqb/gnc-ab-utils.c
@@ -1033,16 +1033,17 @@ bal_accountinfo_cb (AB_IMEXPORTER_ACCOUNTINFO *element, gpointer user_data)
/* Translators: Strings from this file are needed only in
countries that have one of aqbanking's Online Banking
techniques available. This is 'OFX DirectConnect'
- (U.S. and others), 'HBCI' (in Germany), or 'YellowNet'
+ (U.S. and others), 'FinTS' (in Germany), or 'YellowNet'
(Switzerland). If none of these techniques are available
in your country, you may safely ignore strings from the
import-export/hbci subdirectory. */
_("The downloaded Online Banking Balance was zero.\n\n"
"Either this is the correct balance, or your bank does not "
- "support Balance download in this Online Banking version. "
- "In the latter case you should choose a different "
- "Online Banking version number in the Online Banking "
- "(AqBanking or HBCI) Setup. After that, try again to "
+ "support Balance download with the parameters you have "
+ "selected. "
+ "In the latter case you should check the details of "
+ "your connection like Server URL in the Online Banking "
+ "(AqBanking) Setup. After that, try again to "
"download the Online Banking Balance."));
gtk_dialog_run (GTK_DIALOG(dialog));
gtk_widget_destroy (dialog);
diff --git a/gnucash/import-export/aqb/gnc-plugin-aqbanking.ui b/gnucash/import-export/aqb/gnc-plugin-aqbanking.ui
index 5adc4e454a..6ba78d0b65 100644
--- a/gnucash/import-export/aqb/gnc-plugin-aqbanking.ui
+++ b/gnucash/import-export/aqb/gnc-plugin-aqbanking.ui
@@ -62,7 +62,7 @@
<item>
<attribute name="label" translatable="yes">_Online Banking Setupâ¦</attribute>
<attribute name="action">gnc-plugin-aqbanking-actions.ABSetupAction</attribute>
- <attribute name="tooltip" translatable="yes">Initial setup of Online Banking access (HBCI, or OFX DirectConnect, using AqBanking)</attribute>
+ <attribute name="tooltip" translatable="yes">Initial setup of Online Banking access (FinTS or OFX DirectConnect) using AqBanking</attribute>
</item>
</menu>
diff --git a/gnucash/import-export/aqb/gschemas/org.gnucash.GnuCash.dialogs.import.hbci.gschema.xml.in b/gnucash/import-export/aqb/gschemas/org.gnucash.GnuCash.dialogs.import.hbci.gschema.xml.in
index 41c6f40db6..e9f99b8347 100644
--- a/gnucash/import-export/aqb/gschemas/org.gnucash.GnuCash.dialogs.import.hbci.gschema.xml.in
+++ b/gnucash/import-export/aqb/gschemas/org.gnucash.GnuCash.dialogs.import.hbci.gschema.xml.in
@@ -13,12 +13,12 @@
<key name="close-on-finish" type="b">
<default>true</default>
<summary>Close window when finished</summary>
- <description>If active, the window will be closed automatically when you finish the HBCI/AqBanking import process. Otherwise it will stay open.</description>
+ <description>If active, the window will be closed automatically when you finish the AqBanking import process. Otherwise it will stay open.</description>
</key>
<key name="remember-pin" type="b">
<default>false</default>
<summary>Remember the PIN in memory</summary>
- <description>If active, the PIN for HBCI/AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</description>
+ <description>If active, the PIN for AqBanking actions will be remembered in memory during a session. Otherwise it will have to be entered again each time during a session when it is needed.</description>
</key>
<key name="use-ns-transaction-text" type="b">
<default>true</default>
@@ -32,8 +32,8 @@
</key>
<key name="verbose-debug" type="b">
<default>false</default>
- <summary>Verbose HBCI debug messages</summary>
- <description>Enables verbose debug messages for HBCI/AqBanking Online Banking.</description>
+ <summary>Verbose debug messages</summary>
+ <description>Enables verbose debug messages for AqBanking.</description>
</key>
<key name="format-dtaus" type="s">
<default>'default'</default>
commit 9b85edef2e1bb86e6a0c31feef58970f5d1a82f0
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Sun Aug 30 13:48:45 2026 +0800
[gnome/test] fix test-assistant-stock-transaction linked dirs
because it now includes jump to register split
diff --git a/gnucash/gnome/test/CMakeLists.txt b/gnucash/gnome/test/CMakeLists.txt
index 9f66c84e8f..91266f40e5 100644
--- a/gnucash/gnome/test/CMakeLists.txt
+++ b/gnucash/gnome/test/CMakeLists.txt
@@ -40,12 +40,16 @@ set (test_assistant-stock-transaction_INCLUDE_DIRS
${CMAKE_BINARY_DIR}/common
${CMAKE_SOURCE_DIR}/libgnucash/engine
${GNOME_UTILS_GUI_TEST_INCLUDE_DIRS}
+ ${CMAKE_SOURCE_DIR}/gnucash/register/ledger-core
+ ${CMAKE_SOURCE_DIR}/gnucash/register/register-core
+ ${CMAKE_SOURCE_DIR}/gnucash/register/register-gnome
${GNOME_UTILS_GUI_TEST_LIBS}
${GLIB2_INCLUDE_DIRS}
)
set (test_assistant-stock-transaction_LIBS
gnc-engine
+ gnc-gnome
gnc-gnome-utils
gtest
)
commit a133dc007ae2f5e0a7a01a755a28331082deb6c1
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Sun Aug 30 11:26:22 2026 +0800
[assistant-stock-transaction] Jump to new stock transaction
After the stock transaction assistant finishes, open the stock account
register and jump to the transaction just created.
diff --git a/gnucash/gnome/assistant-stock-transaction.cpp b/gnucash/gnome/assistant-stock-transaction.cpp
index 192aa6bac6..97c2c03e00 100644
--- a/gnucash/gnome/assistant-stock-transaction.cpp
+++ b/gnucash/gnome/assistant-stock-transaction.cpp
@@ -54,6 +54,9 @@
#include "gnc-date-edit.h"
#include "gnc-tree-view-account.h"
#include "gnc-ui-util.h"
+#include "gnc-main-window.h"
+#include "gnc-plugin-page-register.h"
+#include "gnc-split-reg.h"
static QofLogModule log_module = GNC_MOD_ASSISTANT;
@@ -2659,9 +2662,26 @@ StockAssistantController::finish()
g_return_if_fail (m_model->txn_type_valid());
gnc_suspend_gui_refresh ();
- [[maybe_unused]] auto [success, trans] = m_model->create_transaction();
+ auto [success, trans] = m_model->create_transaction();
gnc_resume_gui_refresh ();
+ if (success && trans)
+ {
+ auto split = xaccTransFindSplitByAccount (trans, m_model->account());
+ if (split)
+ {
+ auto page = gnc_plugin_page_register_new (m_model->account(), FALSE);
+ gnc_main_window_open_page (nullptr, page);
+ auto gsr = gnc_plugin_page_register_get_gsr (page);
+ gnc_split_reg_raise (gsr);
+
+ if (gnc_split_reg_clear_filter_for_split (gsr, split))
+ gnc_plugin_page_register_clear_current_filter (page);
+
+ gnc_split_reg_jump_to_split (gsr, split);
+ }
+ }
+
gnc_close_gui_component_by_data (ASSISTANT_STOCK_TRANSACTION_CM_CLASS, this);
}
commit 8d261e03413509afb2cf60629a9c857de7b2801b
Author: Claude <noreply at anthropic.com>
Date: Fri Aug 28 14:07:43 2026 +0000
[doclinkcell.c] plug GtkLabel leak in gnc_doclink_cell_set_use_glyphs
The temporary GtkLabel created to test glyph rendering was never
destroyed, leaking a floating widget reference (plus its associated
Pango layout/context allocations) each time the register is loaded,
as reported by valgrind.
Co-Authored-By: Claude Sonnet 5 <noreply at anthropic.com>
Signed-off: Christopher Lam
diff --git a/gnucash/register/register-core/doclinkcell.c b/gnucash/register/register-core/doclinkcell.c
index b1cb0cc2d1..203af2fbc4 100644
--- a/gnucash/register/register-core/doclinkcell.c
+++ b/gnucash/register/register-core/doclinkcell.c
@@ -287,6 +287,8 @@ gnc_doclink_cell_set_use_glyphs (Doclinkcell *cell)
g_object_unref (test_layout);
g_free (test_text);
+ g_object_ref_sink (label);
+ g_object_unref (label);
cell->use_glyphs = use_glyphs;
#endif
Summary of changes:
gnucash/gnome-utils/dialog-preferences.c | 6 +
gnucash/gnome/assistant-stock-transaction.cpp | 22 +-
gnucash/gnome/gnucash.appdata.xml.in.in | 18 +-
gnucash/gnome/test/CMakeLists.txt | 4 +
.../gschemas/org.gnucash.GnuCash.gschema.xml.in | 35 +++
gnucash/gtkbuilder/dialog-preferences.glade | 312 +++++++++++++++++++++
gnucash/import-export/aqb/dialog-ab-pref.glade | 12 +-
gnucash/import-export/aqb/gnc-ab-utils.c | 11 +-
gnucash/import-export/aqb/gnc-plugin-aqbanking.ui | 2 +-
...cash.GnuCash.dialogs.import.hbci.gschema.xml.in | 8 +-
gnucash/import-export/import-parse.cpp | 3 +
gnucash/import-export/test/CMakeLists.txt | 6 +
gnucash/import-export/test/gtest-import-parse.cpp | 213 ++++++++++++++
gnucash/register/register-core/doclinkcell.c | 2 +
gnucash/report/html-chart.scm | 56 +++-
.../report/reports/standard/account-piecharts.scm | 3 +
.../report/reports/standard/category-barchart.scm | 32 +++
gnucash/report/reports/standard/net-charts.scm | 37 ++-
gnucash/report/reports/standard/price-scatter.scm | 33 +--
libgnucash/core-utils/gnc-prefs.h | 7 +
20 files changed, 763 insertions(+), 59 deletions(-)
create mode 100644 gnucash/import-export/test/gtest-import-parse.cpp
More information about the gnucash-changes
mailing list