Sparklines updates on changes in the statistics spreadsheet
Requirements
-
I searched through the issues if the issue already exists
Steps to reproduce
- Create/open a spreadsheet with some data
- show the "statistics spreadsheet" from the context menu of the spreadsheet
Expected
When enabling and disabling some of the statistical metrics in the dock widget, the update in the statistics spreadsheet is fast and smooth.
Observed
Updating of the values is slow which because of the very numerous updates of the sparklines and it looks like we're updating the sparklines on every dataChanged signal for every cell. The sparklines are not activated neither for the parent spreadsheet nor for the statistics spreadsheet, this code shouldn't be called at all in this scenario.
LabPlot Version
Debug build 2.10.0-2314-ga292881b4
Apr 14 2024, 11:07:42
System: openSUSE Leap 15.5
Locale: English,United States (Decimal point '.', Group separator ','
Number settings: Decimal point '.', Group separator ',', Exponential 'e', Zero digit '0', Percent '%', Positive/Negative sign '+'/'-' (Updated on restart)
Architecture: x86_64-little_endian-lp64
Kernel: linux 5.14.21-150500.55.52-default
C++ Compiler: GNU 12.3.0
C++ Compiler Flags: -fno-operator-names -fno-exceptions -Wall -Wextra -Wcast-align -Wchar-subscripts -Wformat-security -Wno-long-long -Wpointer-arith -Wundef -Wnon-virtual-dtor -Woverloaded-virtual -Werror=return-type -Werror=init-self -Wvla -Wdate-time -Wsuggest-override -Wlogical-op -Wall -Wextra -Wundef -Wpointer-arith -Wunreachable-code -Wunused -Wdeprecated-declarations -fno-omit-frame-pointer -fstack-protector -fexceptions -std=c++17 -O2 -Wcast-align -Wswitch-enum -fvisibility=default -pedantic -Wzero-as-null-pointer-constant