Class
PieSeries

Represents a pie chart series that displays data as segments of a circular pie, where each segment represents a data point's proportional value.

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.ChartView.dll

Syntax:

cs-api-definition
public class PieSeries : ChartSeries, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, IStylableElement, IStylableNode, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IShapedElement, IChartSeries, IChartElementPresenter, IAxisProvider

Inheritance: objectDisposableObjectRadObjectUIChartElementChartSeriesPieSeries

Derived Classes: DonutSeries

Implements: IAxisProviderIBorderElementIBoxElementIBoxStyleIChartElementPresenterIChartSeriesICustomTypeDescriptorIDisposableIFillElementINotifyPropertyChangedIShapedElementIStylableElementIStylableNode

Inherited Members ChartSeries.PointSizePropertyChartSeries.LabelFormatPropertyChartSeries.DrawLinesToLabelsPropertyChartSeries.SyncLinesToLabelsColorPropertyChartSeries.LinesToLabelsColorPropertyChartSeries.LabelRotationAnglePropertyChartSeries.OnDataPointIsSelectedChanged(DataPoint)ChartSeries.EnsureVisualState(ChartArea)ChartSeries.ApplyStyleSettingsCore(PropertySettingGroup)ChartSeries.Refresh()ChartSeries.OnPropertyChanged(RadPropertyChangedEventArgs)ChartSeries.CreateDataPointElementCollection()ChartSeries.CreateDataPoint()ChartSeries.CreateDataPointElement(DataPoint)ChartSeries.GetElement(Point)ChartSeries.GetStyleIndex()ChartSeries.HitTest(int, int)ChartSeries.GetDefaultTrackballTextForPoint(DataPoint)ChartSeries.OnCreatePoint(ChartViewCreatePointEventArgs)ChartSeries.OnTrackballPointTextNeeded(TrackballPointTextNeededEventArgs)ChartSeries.SelectedStyleChartSeries.LabelFormatChartSeries.ShowLabelsChartSeries.LabelFormatProviderChartSeries.PointSizeChartSeries.DrawLinesToLabelsChartSeries.SyncLinesToLabelsColorChartSeries.LinesToLabelsColorChartSeries.DataPointsChartSeries.DataSourceChartSeries.DataMemberChartSeries.DisplayMemberChartSeries.FamilyChartSeries.NameChartSeries.AxesChartSeries.BoundsChartSeries.IsVisibleChartSeries.PaletteChartSeries.LabelRotationAngleChartSeries.TrackballFormatStringChartSeries.CreatePointChartSeries.TrackballPointTextNeededUIChartElement.IsVisiblePropertyUIChartElement.ClassPropertyUIChartElement.VisualStatePropertyUIChartElement.IsMouseDownPropertyUIChartElement.IsMouseOverPropertyUIChartElement.FontPropertyUIChartElement.CustomFontPropertyUIChartElement.CustomFontSizePropertyUIChartElement.CustomFontStylePropertyUIChartElement.ForeColorPropertyUIChartElement.BackColorPropertyUIChartElement.BackColor2PropertyUIChartElement.BackColor3PropertyUIChartElement.BackColor4PropertyUIChartElement.NumberOfColorsPropertyUIChartElement.GradientStylePropertyUIChartElement.GradientAnglePropertyUIChartElement.GradientPercentagePropertyUIChartElement.GradientPercentage2PropertyUIChartElement.BorderBoxStylePropertyUIChartElement.BorderDrawModePropertyUIChartElement.BorderWidthPropertyUIChartElement.BorderLeftWidthPropertyUIChartElement.BorderRightWidthPropertyUIChartElement.BorderTopWidthPropertyUIChartElement.BorderBottomWidthPropertyUIChartElement.BorderGradientAnglePropertyUIChartElement.BorderGradientStylePropertyUIChartElement.BorderColorPropertyUIChartElement.BorderColor2PropertyUIChartElement.BorderColor3PropertyUIChartElement.BorderColor4PropertyUIChartElement.BorderInnerColorPropertyUIChartElement.BorderInnerColor2PropertyUIChartElement.BorderInnerColor3PropertyUIChartElement.BorderInnerColor4PropertyUIChartElement.BorderLeftColorPropertyUIChartElement.BorderTopColorPropertyUIChartElement.BorderRightColorPropertyUIChartElement.BorderBottomColorPropertyUIChartElement.BorderLeftShadowColorPropertyUIChartElement.BorderTopShadowColorPropertyUIChartElement.BorderRightShadowColorPropertyUIChartElement.BorderBottomShadowColorPropertyUIChartElement.BackgroundShapePropertyUIChartElement.BorderDashStylePropertyUIChartElement.BorderDashPatternPropertyUIChartElement.BorderCornerRadiusPropertyUIChartElement.ShapePropertyUIChartElement.PaddingPropertyUIChartElement.SmoothingModePropertyUIChartElement.GetValue(RadProperty)UIChartElement.Attach(UIChartElement)UIChartElement.Dettach()UIChartElement.Invalidate()UIChartElement.MeasureContentOverride(ChartNode, object)UIChartElement.DpiScaleChanged(SizeF)UIChartElement.GetScaledFont(float)UIChartElement.GetCurrentShape()UIChartElement.GetThemeEffectiveType()UIChartElement.ApplyStyle()UIChartElement.BuildVisualState()UIChartElement.AddStylePropertySetting(IPropertySetting)UIChartElement.ApplyStyleByIndex(PropertySettingGroup, int)UIChartElement.ParentUIChartElement.LevelUIChartElement.ChildrenUIChartElement.IsMouseDownUIChartElement.IsMouseOverUIChartElement.ViewUIChartElement.ForeColorUIChartElement.FontUIChartElement.BackColorUIChartElement.BackColor2UIChartElement.BackColor3UIChartElement.BackColor4UIChartElement.GradientStyleUIChartElement.GradientAngleUIChartElement.GradientPercentageUIChartElement.GradientPercentage2UIChartElement.NumberOfColorsUIChartElement.BorderLeftColorUIChartElement.BorderTopColorUIChartElement.BorderRightColorUIChartElement.BorderBottomColorUIChartElement.BorderLeftShadowColorUIChartElement.BorderTopShadowColorUIChartElement.BorderRightShadowColorUIChartElement.BorderBottomShadowColorUIChartElement.BorderBoxStyleUIChartElement.BorderDrawModeUIChartElement.BorderWidthUIChartElement.BorderLeftWidthUIChartElement.BorderTopWidthUIChartElement.BorderRightWidthUIChartElement.BorderBottomWidthUIChartElement.BorderGradientAngleUIChartElement.BorderGradientStyleUIChartElement.BorderColorUIChartElement.BorderColor2UIChartElement.BorderColor3UIChartElement.BorderColor4UIChartElement.BorderInnerColorUIChartElement.BorderInnerColor2UIChartElement.BorderInnerColor3UIChartElement.BorderInnerColor4UIChartElement.BorderDashStyleUIChartElement.BorderDashPatternUIChartElement.BorderCornerRadiusUIChartElement.SizeUIChartElement.ShapeUIChartElement.BackgroundShapeUIChartElement.PaddingUIChartElement.SmoothingModeUIChartElement.IsAttachedUIChartElement.DpiScaleFactorUIChartElement.ClassUIChartElement.VisualStateUIChartElement.ThemeRoleUIChartElement.ChildrenHierarchyUIChartElement.StyleUIChartElement.StateManagerUIChartElement.FallbackToDefaultThemeRadObject.BindingContextPropertyRadObject.RadTypeRadObject.ReplaceDefaultDescriptors(PropertyDescriptorCollection)RadObject.ClearPropertyStore()RadObject.SuspendPropertyNotifications()RadObject.ResumePropertyNotifications()RadObject.GetPropertyValue(RadProperty)RadObject.SetDefaultValueOverride(RadProperty, object)RadObject.SetValue(RadProperty, object)RadObject.ResetValue(RadProperty)RadObject.ResetLocalValue(RadProperty)RadObject.ResetValue(RadProperty, ValueResetFlags)RadObject.UpdateValue(RadProperty)RadObject.GetValueSource(RadProperty)RadObject.GetRegisteredRadProperty(string)RadObject.UpdateValueCore(RadPropertyValue)RadObject.SetValueCore(RadPropertyValue, object, object, ValueSource)RadObject.ResetValueCore(RadPropertyValue, ValueResetFlags)RadObject.GetDefaultValue(RadPropertyValue, object)RadObject.CoerceValue(RadPropertyValue, object)RadObject.ShouldSerializeProperty(RadProperty)RadObject.CanRaisePropertyChangeNotifications(RadPropertyValue)RadObject.BindProperty(RadProperty, RadObject, RadProperty, PropertyBindingOptions)RadObject.UnbindProperty(RadProperty)RadObject.GetInheritedValue(RadProperty)RadObject.OnPropertyChanging(RadPropertyChangingEventArgs)RadObject.OnNotifyPropertyChanged(PropertyChangedEventArgs)RadObject.OnShouldSerializeProperty(ShouldSerializePropertyEventArgs)RadObject.IsPropertyCancelable(RadPropertyMetadata)RadObject.PropertyValuesRadObject.PropertyFilterRadObject.RadObjectTypeRadObject.BindingContextRadObject.PropertyChangedRadObject.RadPropertyChangedRadObject.RadPropertyChangingDisposableObject.GetBitState(long)DisposableObject.SetBitState(long, bool)DisposableObject.OnBitStateChanged(long, bool, bool)DisposableObject.Dispose()DisposableObject.Dispose(bool)DisposableObject.PerformDispose(bool)DisposableObject.DisposeUnmanagedResources()DisposableObject.BitStateDisposableObject.EventsDisposableObject.IsDisposingDisposableObject.IsDisposedDisposableObject.DisposedDisposableObject.Disposing

Constructors

PieSeries()

Initializes a new instance of the PieSeries class.

Declaration

cs-api-definition
public PieSeries()

PieSeries(string)

Initializes a new instance of the PieSeries class with the specified value member.

Declaration

cs-api-definition
public PieSeries(string valueMember)

Parameters

valueMember

string

The name of the property that contains the data values for the pie segments.

PieSeries(string, string)

Initializes a new instance of the PieSeries class with the specified value and legend title members.

Declaration

cs-api-definition
public PieSeries(string valueMember, string legendTitleMember)

Parameters

valueMember

string

The name of the property that contains the data values for the pie segments.

legendTitleMember

string

The name of the property that contains the legend titles for the pie segments.

Fields

LabelModeProperty

Identifies the LabelMode dependency property.

Declaration

cs-api-definition
public static readonly RadProperty LabelModeProperty

Field Value

RadProperty

LabelsOffsetFromCenterProperty

Identifies the LabelsOffsetFromCenter dependency property.

Declaration

cs-api-definition
public static readonly RadProperty LabelsOffsetFromCenterProperty

Field Value

RadProperty

RadiusFactorProperty

Identifies the RadiusFactor dependency property.

Declaration

cs-api-definition
public static readonly RadProperty RadiusFactorProperty

Field Value

RadProperty

Properties

LabelMode

Gets or sets the label positioning mode for the pie chart labels.

Declaration

cs-api-definition
public PieLabelModes LabelMode { get; set; }

Property Value

PieLabelModes

LabelsOffsetFromCenter

Gets or sets the distance multiplier that determines how far labels are positioned from the center of the pie.

Declaration

cs-api-definition
public float LabelsOffsetFromCenter { get; set; }

Property Value

float

LegendTitleMember

Gets or sets the name of the data source property that provides legend titles for the pie segments.

Declaration

cs-api-definition
[Browsable(true)]
public string LegendTitleMember { get; set; }

Property Value

string

Model

Gets the data model that represents the pie series structure and behavior.

Declaration

cs-api-definition
public override ChartSeriesModel Model { get; }

Property Value

ChartSeriesModel

Overrides ChartSeries.Model

RadiusFactor

Gets or sets a multiplier that determines the final radius of the pie chart relative to its default size.

Declaration

cs-api-definition
public float RadiusFactor { get; set; }

Property Value

float

Range

Gets or sets the angular range that defines the starting and sweep angles of the pie chart.

Declaration

cs-api-definition
public AngleRange Range { get; set; }

Property Value

AngleRange

ValueMember

Gets or sets the name of the data source property that provides values for the pie segments.

Declaration

cs-api-definition
[Browsable(true)]
public string ValueMember { get; set; }

Property Value

string

Methods

BindMembers()

Binds the data members to the appropriate data point properties.

Declaration

cs-api-definition
protected override void BindMembers()

Overrides ChartSeries.BindMembers()

CreateDefaultDataPoint()

Creates a default pie data point for the series.

Declaration

cs-api-definition
protected override DataPoint CreateDefaultDataPoint()

Returns

DataPoint

A new DataPoint instance suitable for pie charts.

Overrides ChartSeries.CreateDefaultDataPoint()

CreateModel()

Creates the data model for the pie series and initializes the data point collection.

Declaration

cs-api-definition
protected override ChartDataPointCollection CreateModel()

Returns

ChartDataPointCollection

A ChartDataPointCollection containing the pie data points.

Overrides ChartSeries.CreateModel()

CreatePointElement(DataPoint)

Creates a visual element for the specified pie data point.

Declaration

cs-api-definition
protected override DataPointElement CreatePointElement(DataPoint point)

Parameters

point

DataPoint

The data point for which to create the visual element.

Returns

DataPointElement

A DataPointElement representing the pie segment.

Overrides ChartSeries.CreatePointElement(DataPoint)

DisposeManagedResources()

Releases the managed resources used by the pie series.

Declaration

cs-api-definition
protected override void DisposeManagedResources()

Overrides ChartSeries.DisposeManagedResources()

GetPieSegmentColors(int)

Gets the palette entry for the pie segment at the specified index.

Declaration

cs-api-definition
public PaletteEntry GetPieSegmentColors(int i)

Parameters

i

int

The index of the pie segment.

Returns

PaletteEntry

A PaletteEntry containing the colors for the segment, or null if no palette is available.

OnApplyPalette()

Applies the current palette to all pie point elements, setting their background and border colors.

Declaration

cs-api-definition
protected override void OnApplyPalette()

Overrides ChartSeries.OnApplyPalette()

OnAttached(UIChartElement)

Called when the series is attached to a parent chart element.

Declaration

cs-api-definition
protected override void OnAttached(UIChartElement parent)

Parameters

parent

UIChartElement

The parent chart element, which must be a PieArea.

Overrides ChartSeries.OnAttached(UIChartElement)

OnDettached()

Called when the series is detached from its parent chart element.

Declaration

cs-api-definition
protected override void OnDettached()

Overrides ChartSeries.OnDettached()

OnNotifyPropertyChanged(string)

Raises the property changed event and updates the data model.

Declaration

cs-api-definition
protected override void OnNotifyPropertyChanged(string propertyName)

Parameters

propertyName

string

The name of the property that changed.

Overrides RadObject.OnNotifyPropertyChanged(string)

ValidatePoint(DataPoint)

Validates that the specified data point is compatible with this pie series.

Declaration

cs-api-definition
protected override void ValidatePoint(DataPoint item)

Parameters

item

DataPoint

The data point to validate.

Overrides ChartSeries.ValidatePoint(DataPoint)