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 603 - OnGetAxisLabel even handler causes wrong height of horizontal axis title
Summary: OnGetAxisLabel even handler causes wrong height of horizontal axis title
Status: RESOLVED FIXED
Alias: None
Product: VCL TeeChart
Classification: Unclassified
Component: Axis (show other bugs)
Version: 140220
Hardware: PC Windows
: --- blocker
Target Milestone: ---
Assignee: Steema Issue Manager
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-26 04:23 EST by trubetskov
Modified: 2014-02-28 06:36 EST (History)
2 users (show)

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


Attachments
Delphi XE project demonstrating this problem. See comments in the code and Chart_bug1.png (89.60 KB, application/zip)
2014-02-26 04:23 EST, trubetskov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description trubetskov 2014-02-26 04:23:26 EST
Created attachment 101 [details]
Delphi XE project demonstrating this problem. See comments in the code and Chart_bug1.png

OnGetAxisLabel even handler causes wrong height of horizontal axis title - there is an obvious problem in a new code in the TChartAxis.InternalCalcSize function.

I attached an example reproducing this problem. If you remove empty even handler - plotting reverts to normal.
Comment 1 david berneda 2014-02-28 06:36:58 EST
Fixed. There was an oversight, sorry. 
New code at InternalCalcSize should be:

    if Assigned(ParentChart.FOnGetAxisLabel) then
       tmpHeight:=Horizontal  // <---- FIXED BUG 
    else
       tmpHeight:=( Horizontal and ((tmpAngle=0) or (tmpAngle=180))) or
                  ( (not Horizontal) and ((tmpAngle=90) or (tmpAngle=270)));