Jump to content
Software FX Community

Multi-series 3D pie charts


Mick

Recommended Posts

When I create a pie chart that has 2 series - 2 pie charts in a single instance of the chart control - and make it 3D, there is a jarring effect when I switch between the 2 pies: Instead of a smooth transition between the charts (one getting bigger smoothly, and the other getting smaller smoothly), the main chart instantly gets set to the right height (so it is a sideways oval shape), and the width is slowly adjusted to match during the slide animation where the main chart becomes the side chart. The same effect is present when the extra chart is on the bottom instead of the side (but switch what happens to the height/width).

In addition, the chart titles seem to be linked to the resizing algorithm. Because both the main and the side charts have the same sized text (in my application and your demo), I don't see any reason that they should be resized at all.

You can see this effect happening in the online XBAP demo, but here it only happens to the chart title. I don't see the code that was used to create the demo, but I presume that if you change it from having 4 series to 2 series, you will see the same effect that I described.

I have attached a picture to better explain the effect I am seeing (this is during a horizontal chart swap)

Posted Image

Thank you,

Mick

Link to comment
Share on other sites

>> pie gets resized into an oval before starting the animation

This is an issue because from a layout point of view there are 2 columns and the extra series share the space in the 2nd column. When there is only 2 series the second series will then occupy the total height, because pie charts want to be round then internally we will limit the height.

The code used for the animation was not taking the fact that the chart will use less height into account when animating the RenderTransform, we have uploaded a new hotfix build (marked 3544 or later). Note that this was independent of whether the chart was 2D or 3D. It might be more obvious in 3D because rendering the 3D chart is slower.

>> the chart titles seem to be linked to the resizing algorithm

Unfortunately the code that handles the animation have no knowledge of the things being animated, in a pie chart with titles there is an extra panel that contains the title and plotarea. It is not possible for us to tweak this without a major rewrite.

We have added a boolean property to AnimationAttributes called OnPanelTransitions that you can use to turn off this animation if desired, e.g. chart1.Animation.OnPanelTransitions = false;

Regards,

JuanC

Link to comment
Share on other sites

Thank you,

In regards to the second issue, is there any way that I can specify the font size for both the main chart and any auxilliary chart? If so, the problem of a "flicker effect" could be reduced / eliminated as follows:

If the main chart is 4 times as big as the small chart, I can make the title 4 times the size. That way, the growing / shrinking algorithm gives the chart a smooth transition from big->small or small->big.

I assume that your code does something like pre-renders the chart+title at either size (big or small), and then provides simple transforms to switch the positions of the charts. As the text title may not be a TextBlock anymore, I understand the distortion. However, I would really like to use 3d charts without this effect, and I'm willing to have the chart titles have different sizes.

If this is possible, how do I do it? If not, is there a forum where I can submit a feature request?

Thank you,

Mick

Link to comment
Share on other sites

We use the series.Content for the different panes in a pie chart so you could use different fonts by using your own visuals but there is no built-in fuctionality that would allow you to set the title size to be smaller in the panes that are not the "main" pane and we do not fire an event when you click on one of the smaller panes.

Note that internally we treat them differently, for example highlight and tooltips are disabled in the smaller pies, so it would certainly be possible to add a property that allows you to shrink those titles.

That being said, if you resize the titles to be 4x smaller they will probably be unreadable and I am not sure I would sacrifice the readability of the chart because of the transition effect. If I was you I would probably remove the animation with the OnPanelTransitions property.

Something else we have considered is to align the title in the 3D pie charts similarly to what we do in 2D where the title is close to the pie (instead of at the top of its available space). The issue with this would be that the title would have to be moved if you rotate the pie.

This is the right forum to submit and discuss feature requests. We appreciate all the feedback.

JuanC

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...