Steema Issues Database

Note: 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.



Bug 2135 - "Control '' has no parent window" error in LegendPaletteTool when default new canvas is GDI
Summary: "Control '' has no parent window" error in LegendPaletteTool when default new...
Status: RESOLVED WORKSFORME
Alias: None
Product: VCL TeeChart
Classification: Unclassified
Component: Tools (show other bugs)
Version: unspecified
Hardware: PC Windows
: --- enhancement
Target Milestone: ---
Assignee: Steema Issue Manager
URL: https://www.steema.com/support/viewto...
Keywords:
Depends on:
Blocks:
 
Reported: 2018-12-20 04:42 EST by yeray alonso
Modified: 2023-03-15 15:19 EDT (History)
2 users (show)

See Also:
Chart Series: ---
Delphi / C++ Builder RAD IDE Version:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description yeray alonso 2018-12-20 04:42:41 EST
Steps to reproduce the error:

- Drop a TChart to the form
- Open the design time "Options" through the contextual menu.
  - Make sure "GDI" is selected as "Render" at the "New Chart" tab.
- Add this code at OnCreate:

  Chart1.Tools.Add(TLegendPaletteTool);

You don't need any series on the chart.

- Run and move the mouse over the chart.

Here the Call Stack:

:75811812 KERNELBASE.RaiseException + 0x62
:0047fb0f TWinControl.CreateWnd + $B3
:0047ffe0 TWinControl.CreateHandle + $1C
:0045f4eb TCanvas.RequiredState + $2B
TeCanvas.TTeeCanvas.SetInterCharSize(0)
TeCanvas.TTeeCanvas.DoChangedFont
TeCanvas.TTeeCanvas.AssignFontSize($263D130,8)
TeCanvas.TTeeCanvas.AssignFont($263D130)
TeEngine.TAxisItems.InitCalcRect
TeEngine.CheckMouse($25630B0)
TeEngine.ProcessAxis($25630B0,False)
TeEngine.TCustomAxisPanel.CheckMouseAxes(390,232)
Chart.TCustomChart.MouseMove([],390,232)
TeeLegendPalette.TLegendPaletteTool.ChartMouseEvent(cmeMove,mbLeft,[],390,232)
Chart.CheckList($2605180)
Chart.TCustomChart.BroadcastMouseEvent(cmeMove,mbLeft,[],390,232)
Chart.TCustomChart.MouseMove([],390,232)
:0047cf57 TControl.WMMouseMove + $83

A workaround could be to set "GDI+" as "Render" at the "New Chart" tab in the design time "Options", and then set the Chart to use GDI:

  Chart1.Canvas:=TTeeCanvas3D.Create;
Comment 1 david berneda 2023-03-15 15:19:13 EDT
Cannot reproduce. 
Changes in recent versions should have fixed this issue.