New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Defines the fluent interface for configuring pyramid series.

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Type Parameters:

T

The type of the data item

Syntax:

C#
public class ChartPyramidSeriesBuilder<T> where T : class

Inheritance: objectChartPyramidSeriesBuilder<T>

Inherited Members object.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

Initializes a new instance of the ChartPyramidSeriesBuilder<T> class.

C#
public ChartPyramidSeriesBuilder(IChartPyramidSeries series)
Parameters:seriesIChartPyramidSeries

The series.

Properties

Gets or sets the series.

C#
public IChartPyramidSeries Series { get; }
Property Value:

The series.

Methods

Configures the pyramid border

C#
public ChartPyramidSeriesBuilder<T> Border(Action<ChartBorderBuilder> configurator)
Parameters:configuratorAction<ChartBorderBuilder>

The border configuration action

Returns:

ChartPyramidSeriesBuilder<T>

Sets the pyramid segments border

C#
public ChartPyramidSeriesBuilder<T> Border(int width, string color, ChartDashType dashType)
Parameters:widthint

The pyramid segments border width.

colorstring

The pyramid segments border color (CSS syntax).

dashTypeChartDashType

The pyramid segments border dash type.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).Border(1, "#000", ChartDashType.Dot))
)

Sets the dynamic height of the pyramid chart.

C#
public ChartPyramidSeriesBuilder<T> DynamicHeight(bool dynamicHeight)
Parameters:dynamicHeightbool

A boolean parameter for the dynamic height of a pyramid serie.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).DynamicHeight(true))
)

Configures the pyramid chart labels.

C#
public ChartPyramidSeriesBuilder<T> Labels(Action<ChartPyramidLabelsBuilder> configurator)
Parameters:configuratorAction<ChartPyramidLabelsBuilder>

The configuration action.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series
.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString)
.Labels(labels =&gt; labels
.Color("red")
.Visible(true)
)
)
)

Sets the visibility of pyramid chart labels.

C#
public ChartPyramidSeriesBuilder<T> Labels(bool visible)
Parameters:visiblebool

The visibility. The default value is false.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series
.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString)
.Labels(true)
)
)

Sets the name of the series.

C#
public ChartPyramidSeriesBuilder<T> Name(string text)
Parameters:textstring

The text for a pyramid serie.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart(Model)
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).Name("Sales"))
)

Sets the opacity of the pyramid series.

C#
public ChartPyramidSeriesBuilder<T> Opacity(double opacity)
Parameters:opacitydouble

The opacity for a pyramid serie.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).Opacity(0.3))
)

The chart series pattern configuration options.

C#
public ChartPyramidSeriesBuilder<T> Pattern(Action<ChartSeriesPatternSettingsBuilder> configurator)
Parameters:configuratorAction<ChartSeriesPatternSettingsBuilder>

The configurator for the Pattern setting.

Returns:

ChartPyramidSeriesBuilder<T>

Sets the data item field which contains the series pattern configuration for individual chart segments.

C#
public ChartPyramidSeriesBuilder<T> PatternField(string value)
Parameters:valuestring

The data item field which contains the series pattern configuration for individual chart segments

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart(Model)
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).PatternField("Pattern"))
)

Sets the segmentSpacing of the chart.

C#
public ChartPyramidSeriesBuilder<T> SegmentSpacing(double segmentSpacing)
Parameters:segmentSpacingdouble

The segment spacing for a pyramid serie.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("Chart")
.Series(series =&gt; series.Pyramid(s =&gt; s.Sales, s =&gt; s.DateString).SegmentSpacing(5))
)

Configure the series tooltip.

C#
public ChartPyramidSeriesBuilder<T> Tooltip(Action<ChartTooltipBuilder> configurator)
Parameters:configuratorAction<ChartTooltipBuilder>

Use the configurator to set the tooltip options.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart().Name("chart")
.Series(series =&gt;
series.Pyramid(new dynamic[]{
new { category= "Impressions ", value= 434823, color= "#0e5a7e" },
new { category= "Clicks", value= 356854, color= "#166f99" }
}).Tooltip(tooltip =&gt; tooltip.Border(border =&gt; border.Color("#ff0000")))
)
)

Sets the tooltip visibility.

C#
public ChartPyramidSeriesBuilder<T> Tooltip(bool visible)
Parameters:visiblebool

A value indicating if the tooltip should be displayed.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart().Name("chart")
.Series(series =&gt;
series.Pyramid(new dynamic[]{
new { category= "Impressions ", value= 434823, color= "#0e5a7e" },
new { category= "Clicks", value= 356854, color= "#166f99" }
}).Tooltip(true)
)
)

Sets the series visual handler

C#
public ChartPyramidSeriesBuilder<T> Visual(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart()
.Name("chart")
.Series(series =&gt;
{
series.Pyramid(new dynamic[]{
new { category= "Impressions ", value= 434823, color= "#0e5a7e" },
new { category= "Clicks", value= 356854, color= "#166f99" }
}).Visual(
@&lt;text&gt;
function(e) {
return e.createVisual(); // returns the default visual
}
&lt;/text&gt;
);
})
)

Sets the series visual handler

C#
public ChartPyramidSeriesBuilder<T> Visual(string handler)
Parameters:handlerstring

The JavaScript function name.

Returns:

ChartPyramidSeriesBuilder<T>

Example:
C#
@(Html.Kendo().Chart().Name("chart")
.Series(series =&gt;
series.Pyramid(new dynamic[]{
new { category= "Impressions ", value= 434823, color= "#0e5a7e" },
new { category= "Clicks", value= 356854, color= "#166f99" }
}).Visual("pyramidVisual")
)
)