![]() | Steema Issues DatabaseNote: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;otherwise you can use StackOverflow. Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy. |
| Summary: | Abnormal Crash in TeeChart - using "Other Slice" value | ||
|---|---|---|---|
| Product: | VCL TeeChart | Reporter: | Bradley MacDonald <brad> |
| Component: | Chart | Assignee: | yeray alonso <yeray> |
| Status: | RESOLVED FIXED | ||
| Severity: | major | CC: | brad, yeray |
| Priority: | --- | ||
| Version: | 20.170306 | ||
| Target Milestone: | v2017.20 | ||
| Hardware: | PC | ||
| OS: | Windows | ||
| Chart Series: | Pie | Delphi / C++ Builder RAD IDE Version: | RAD 10.1 Berlin |
| Attachments: | Sample Project - TeeChart Crash on Mouse Over | ||
|
Description
Bradley MacDonald
2017-01-25 22:34:44 EST
I can't see the attachment, could you please try to upload it again? Created attachment 705 [details]
Sample Project - TeeChart Crash on Mouse Over
You can also download it from www.timeacct.com/files/TeeChartIssue.zip. This download contains the compiled program as well as the source. It demonstrates the issue every time.
Let me know if you have any problems getting the sample project.
I can reproduce the problem with the given application. Thanks for attaching it, Bradley.
It seems the problem happens when the series is repainted.
If you aren't interested on the Hover feature, you can disable it and the chart won't be repainted when you move the mouse over it:
Chart_Dir.Hover.Visible:=False;
Yeray Thank you for the update. I am glad you can reproduce it - and it was not just me :) Thank you for the work around - and I will look forward to the patch when it is available. Bradley We have a fix proposal pending to investigate if it causes any collateral damage.
Feel free to test it for your purposes.
It consists on three small modifications at TeEngine.pas:
- At ´RefreshLinked´ procedure, nested inside ´TChartSeries.NotifyValue´, substitute this:
veDelete : if rOnDelete in FRecalcOptions then
if FunctionType=nil then
DeletedValue(Self,ValueIndex);
for this:
veDelete : if rOnDelete in FRecalcOptions then
if (FunctionType=nil) and (ValueIndex<Count) then
DeletedValue(Self,ValueIndex);
- At the end of ´TChartSeries.AddXY´ function, remove these lines:
if IUpdating=0 then
NotifyNewValue(Self,result);
- At the end of ´TLabelsList.InsertLabel´ procedure, add this line:
Series.NotifyValue(veModify,ValueIndex);
Hello Yeray, There are two places where there is a TEEngine.pas file. C:\Delphi\Components\TeeChartPro\Source and C:\Delphi\Components\TeeChartPro\Source\VCL which one should I modify for testing? I also noted that the path (library) is set to (C:\Delphi\Components\TeeChartPro\Compiled\Delphi24.win32\Lib). What is the best way to get the DCU into that directory? Just copy it? Or is there a specific process I should follow? Bradley We ended implementing a different approach, consisting on incrementing and decrementing IUpdating variable to prevent propagating the changes in the middle of the repaint process.
At Series.pas unit:
line 10490:
Inc(IUpdating);
Delete(t);
Dec(IUpdating);
line 10566:
Inc(IUpdating);
XValues.FillSequence;
Dec(IUpdating);
line 10595:
Inc(IUpdating);
t:=AddXY(TeePieOtherFlag,tmpValue,FOtherSlice.Text,FOtherSlice.Color);
Dec(IUpdating);
The recommended way to modify the sources is to modify the files at the "Source" folder and run "TeeRecompile.exe" utility to generate both the sources in the "VCL" / "FMX" folders, and the binaries in the "Compiled" folders.
Thank you very much for the update and the notes about the proper way to compile the changes! |