[html-chart] change default mode to 'index and intersect #f

Will enable tooltips over the chart canvas, instead of requiring the
mouse to hover near the data point.
This commit is contained in:
Christopher Lam
2024-11-29 22:50:31 +08:00
parent 555e23e8b5
commit 28fec407aa
2 changed files with 2 additions and 4 deletions

View File

@@ -212,6 +212,8 @@
(cons 'point (list
(cons 'pointStyle #f)))))
(cons 'tooltips (list
(cons 'mode 'index)
(cons 'intersect #f)
(cons 'callbacks (list
(cons 'label #f)))))

View File

@@ -291,10 +291,6 @@ date point, a projected minimum balance including scheduled transactions."))
(gnc:html-chart-set-currency-symbol!
chart (gnc-commodity-get-nice-symbol currency))
;; Allow tooltip in whole chartarea
(gnc:html-chart-set! chart '(options tooltips mode) "index")
(gnc:html-chart-set! chart '(options tooltips intersect) #f)
;; We're done!
(gnc:html-document-add-object! document chart)
(gnc:report-finished))))