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

Defines the fluent API for configuring the DiagramShapeFillSettings settings.

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Type Parameters:

TShapeModel

TConnectionModel

Syntax:

C#
public class DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel> where TShapeModel : class where TConnectionModel : class

Inheritance: objectDiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel>

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

Constructors

C#
public DiagramShapeFillSettingsBuilder(DiagramShapeFillSettings settings)
Parameters:settingsDiagramShapeFillSettings

Methods

Defines the fill color of the shape.

C#
public DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel> Color(string value)
Parameters:valuestring

The value that configures the color.

Returns:

DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel>

Example:
C#
@(Html.Kendo().Diagram()
.Name("diagram")
.Shapes(shape =&gt; shape
.Add().Fill(f =&gt; f.Color("lime"))
)
)

Defines the gradient fill of the shape.

C#
public DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel> Gradient(Action<DiagramShapeFillGradientSettingsBuilder<TShapeModel, TConnectionModel>> configurator)
Parameters:configuratorAction<DiagramShapeFillGradientSettingsBuilder<TShapeModel, TConnectionModel>>

The action that configures the gradient.

Returns:

DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel>

Example:
C#
@(Html.Kendo().Diagram()
.Name("diagram")
.Shapes(shape =&gt; shape
.Add().Fill(f =&gt; f.Gradient(g =&gt; g.Type("radial").Center(new double[] { 0.5, 0.5 }).Radius(0.9)))
)
)

Defines the fill opacity of the shape.

C#
public DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel> Opacity(double value)
Parameters:valuedouble

The value that configures the opacity.

Returns:

DiagramShapeFillSettingsBuilder<TShapeModel, TConnectionModel>

Example:
C#
@(Html.Kendo().Diagram()
.Name("diagram")
.Shapes(shape =&gt; shape
.Add().Fill(f =&gt; f.Opacity(0.5))
)
)