SplitButton
Kendo UI SplitButton component
Definition
Namespace:Kendo.Mvc.UI
Assembly:Kendo.Mvc.dll
Syntax:
public class SplitButton : WidgetBase, IWidget, IHtmlAttributesContainer, IScriptableComponent
Inheritance: objectWidgetBaseSplitButton
Implements:
Inherited Members
Constructors
Initializes a new instance of the SplitButton class.
public SplitButton(ViewContext viewContext, IJavaScriptInitializer initializer, IUrlGenerator urlGenerator)
The view context
initializerIJavaScriptInitializerThe JavaScriptInitializer
urlGeneratorIUrlGeneratorThe URL generator.
Properties
The icon rendered for the arrow button of the SplitButton.
public string ArrowIcon { get; set; }
Indicates whether the SplitButton should be enabled or disabled. By default, it is enabled, unless a disabled="disabled" attribute is detected.
public bool? Enabled { get; set; }
Sets a value controlling how the color is applied.
public FillMode? FillMode { get; set; }
Defines a name of an existing icon in the Kendo UI theme sprite. The icon will be applied as background image of a span element inside the SplitButton. The span element can be added automatically by the widget, or an existing element can be used, if it has a k-icon CSS class applied. For a list of available icon names, please refer to the Icons demo.
public string Icon { get; set; }
Defines a CSS class - or multiple classes separated by spaced - which are applied to a span element inside the SplitButton. Allows the usage of custom icons.
public string IconClass { get; set; }
Defines a URL, which will be used for an img element inside the SplitButton. The URL can be relative or absolute. In case it is relative, it will be evaluated with relation to the web page URL.The img element can be added automatically by the widget, or an existing element can be used, if it has a k-image CSS class applied.
public string ImageUrl { get; set; }
Specifies the menu buttons of the SplitButton.
public List<SplitButtonItem> Items { get; set; }
Specifies a custom template for the menu items.
public string ItemTemplate { get; set; }
The handler for the ItemTemplate
public string ItemTemplateHandler { get; set; }
The id for the ItemTemplate
public string ItemTemplateId { get; set; }
Allows localization of the strings that are used in the widget.
public SplitButtonMessagesSettings Messages { get; set; }
The options that will be used for the popup initialization. For more details about the available options refer to Popup documentation.
public SplitButtonPopupSettings Popup { get; set; }
Sets the size of the component.
public ComponentSize? Size { get; set; }
Defines a CSS class (or multiple classes separated by spaces), which will be used for applying a background image to a span element inside the SplitButton. In case you want to use an icon from the Kendo UI theme sprite background image, it is easier to use the icon property.The span element can be added automatically by the widget, or an existing element can be used, if it has a k-sprite CSS class applied.
public string SpriteCssClass { get; set; }
Sets the color of the component according to the applied theme.
public ThemeColor? ThemeColor { get; set; }
Methods
public override IDictionary<string, object> Serialize()
Overrides:
Writes the HTML.
protected override void WriteHtml(HtmlTextWriter writer)
The HtmlTextWriter.
Overrides:
Writes the initialization script.
public override void WriteInitializationScript(TextWriter writer)
The TextWriter.
Overrides: