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

Provides a fluent interface for configuring color picker tools in the Editor.

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Syntax:

C#
public class EditorColorPickerToolBuilder

Inheritance: objectEditorColorPickerToolBuilder

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

Constructors

C#
public EditorColorPickerToolBuilder(EditorColorPickerTool tool)
Parameters:toolEditorColorPickerTool

Methods

Specifies the color columns for "FontColor" and "BackColor" tools when a list of colors is defined.

C#
public EditorColorPickerToolBuilder Columns(int columns)
Parameters:columnsint

The number of columns.

Returns:

EditorColorPickerToolBuilder

Example:
C#
@(Html.Kendo().Editor()
.Name("Editor")
.Tools(tools => tools
.FontColor(config => config
.Palette(new string[] { "#ffff00", "#db9791" })
.Columns(2)
)
)
)

Specifies the color palette for "FontColor" and "BackColor" tools.

C#
public EditorColorPickerToolBuilder Palette(ColorPickerPalette palette)
Parameters:paletteColorPickerPalette

The ColorPickerPalette palette.

Returns:

EditorColorPickerToolBuilder

Example:
C#
@(Html.Kendo().Editor()
.Name("Editor")
.Tools(tools => tools
.FontColor(config => config.Palette(ColorPickerPalette.WebSafe))
.BackColor(config => config.Palette(ColorPickerPalette.Basic))
)
)

Specifies a list of colors for "FontColor" and "BackColor" tools.

C#
public EditorColorPickerToolBuilder Palette(IEnumerable<string> palette)
Parameters:paletteIEnumerable<string>

The collection of colors.

Returns:

EditorColorPickerToolBuilder

Example:
C#
@(Html.Kendo().Editor()
.Name("Editor")
.Tools(tools =&gt; tools
.FontColor(config =&gt; config.Palette(new string[] { "#ffffff", "#ffff00", "#db9791" }))
.BackColor(config =&gt; config.Palette(new string[] { "#ffffff", "#ffff00", "#db9791" }))
)
)