This is a migrated thread and some comments may be shown as answers.

Very large (width) chart renders with aliasing

1 Answer 27 Views
Chart
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Nathanael
Top achievements
Rank 2
Nathanael asked on 28 Jun 2015, 04:34 PM

Hi,

Here's a repro app : a long table of values (200 values=8000pixels) that I can horizontally scroll.
I'd like to put below a chart using those figures. Everything works great except that it renders poorly : my series is totally aliased with the stretching.

<ScrollViewer HorizontalScrollMode="Enabled" HorizontalScrollBarVisibility="Auto" VerticalScrollMode="Disabled" VerticalScrollBarVisibility="Disabled">
    <StackPanel>
        <ItemsControl x:Name="Items" ItemsSource="{Binding Path=DataSource}">
            <ItemsControl.ItemTemplate>
                <DataTemplate>
                    <StackPanel Orientation="Vertical" Width="40">
                        <TextBlock Text="{Binding Path=Category}" />
                        <TextBlock Text="{Binding Path=Value}" />
                    </StackPanel>
                </DataTemplate>
            </ItemsControl.ItemTemplate>
            <ItemsControl.ItemsPanel>
                <ItemsPanelTemplate>
                    <StackPanel Orientation="Horizontal" />
                </ItemsPanelTemplate>
            </ItemsControl.ItemsPanel>
        </ItemsControl>
        <chart:RadCartesianChart>
            <chart:RadCartesianChart.HorizontalAxis>
                <chart:CategoricalAxis />
            </chart:RadCartesianChart.HorizontalAxis>
            <chart:AreaSeries ItemsSource="{Binding Path=DataSource}">
                <chart:AreaSeries.VerticalAxis>
                    <chart:LinearAxis Minimum="0" Maximum="100" Visibility="Collapsed" />
                </chart:AreaSeries.VerticalAxis>
                <chart:AreaSeries.CategoryBinding>
                    <chart:PropertyNameDataPointBinding PropertyName="Category" />
                </chart:AreaSeries.CategoryBinding>
                <chart:AreaSeries.ValueBinding>
                    <chart:PropertyNameDataPointBinding PropertyName="Value" />
                </chart:AreaSeries.ValueBinding>
            </chart:AreaSeries>
        </chart:RadCartesianChart>
        <TextBlock Text="{Binding Path=ActualWidth, ElementName=Items}"/>
    </StackPanel>
</ScrollViewer>
 

What can I do make it work correctly ?

1 Answer, 1 is accepted

Sort by
0
Tsvyatko
Telerik team
answered on 01 Jul 2015, 12:19 PM
Hello Nathanael,

Thank you for sending us code snippet and screenshot describing the issue you are facing!

We have reviewed the scenario you are trying to achieve and the result you are currently getting. Due to the fact that RadChart uses Microsoft Path primitive to display its points it has the same limitations as the primitive itself.

Depending on the scenario you are trying to achieve you might want to utilize Chart PanAndZoom Behavior. It will enable render of large data onto the chart and provide ability for UI virtualization, Pan Zoom in/out. More information regarding its usage can be found here - http://docs.telerik.com/windows-universal/controls/radchart/behaviors/chartpanandzoombehavior

Please have a look and let us know if this helps.

Regards,
Tsvyatko
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Chart
Asked by
Nathanael
Top achievements
Rank 2
Answers by
Tsvyatko
Telerik team
Share this question
or