![]() | 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: | [TV52014696] A customer proposed an override of the event OnDraxAxisLabel: now: ... | ||
|---|---|---|---|
| Product: | VCL TeeChart | Reporter: | yeray alonso <yeray> |
| Component: | Axis | Assignee: | Steema Issue Manager <issuemanager> |
| Status: | CONFIRMED --- | ||
| Severity: | enhancement | CC: | linus.hogrebe |
| Priority: | High | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Chart Series: | --- | Delphi / C++ Builder RAD IDE Version: | |
|
Description
yeray alonso
2015-08-18 06:40:32 EDT
Another customer suggests us to have an extra event instead of changing the actual OnGetAxisLabel:
"In case changing the existing callback is problematic due to compatibility reasons, an alternative might be to provide an additional one, such as shown below?
Function TChartAxis.LabelValue(Const Value:Double):String;
var tmp : String;
Begin
///////////////////////////////////////////////////////////////
if Assigned(ParentChart.FOnGetCustomAxisLabel) then
Result := ParentChart.FOnGetCustomAxisLabel(TChartAxis(Self), Value)
///////////////////////////////////////////////////////////////
else
begin
if IAxisDateTime then
begin
if FDateTimeFormat='' then tmp:=DateTimeDefaultFormat(IRange)
else tmp:=FDateTimeFormat;
DateTimeToString(result,tmp,Value);
end
else
result:=FormatFloat(FAxisValuesFormat,Value);
if Assigned(ParentChart.FOnGetAxisLabel) then
ParentChart.FOnGetAxisLabel(TChartAxis(Self),nil,-1,Result);
if FLabels.MultiLine then
result:=ReplaceChar(result,' ',TeeLineSeparator);
end;
end;"
http://www.teechart.net/support/viewtopic.php?p=69719&#p69719
|