![]() |
User-defined text for chart points, how? |
Post Reply ![]() |
Author | |
wssdev ![]() Groupie ![]() Joined: 04 May 2010 Status: Offline Points: 19 |
![]() ![]() ![]() ![]() ![]() Posted: 16 March 2012 at 7:22am |
[XTP Toolkit 15.13, Windows 7 64-bit]
I'm using string IDs to construct my chart points. It seems that there is no way to control what gets displayed along X axis for each point, because the chart uses precisely those string IDs and not some other text that I could eventually provide. CXTPChartSeriesPoint offers no method for saying what should be displayed. An example: if my point has an ID of "A/B/C/D" I wish to display something like "This is my point made of A, B, C and D". Now, I *could* use the text "This is my point made of A, B, C and D" as my ID but that would not solve the problem because I might actually display something entirely different from the passed ID. I might even need to have two points with different IDs but with the *same* text displayed for both points on X axis. I know that there is an internal ID that is actually used for identifying points. I discovered that it is possible to set this ID programmatically to something unique and have (potentially) a non-unique string ID. However, when I do that, my internal IDs later get erased by this code in XTPChartScaleTypeMap.cpp void CXTPChartQualitativeScaleTypeMap::UpdateSeriesPointArgument(CXTPChartSeriesPoint* pPoint) { pPoint->SetInternalArgument(ValueToInternal(pPoint->GetArgument())); } XTP code obviously enforces the relation between the string ID being displayed and the internal ID. That's something that perhaps should not be insisted upon. If the internal numeric ID is what is used to uniquely identify the point, why can't I set what I want for the text? Note: I know that I can set custom labels and/or tooltips; what I want to change is the text along the X axis. Thanks in advance for any help on how to solve this. ▼ ▲ |
|
![]() |
Post Reply ![]() |
|
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |