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

QRCode

Class

Kendo UI QRCode component

Definition

Constructors

Initializes a new instance of the QRCode class.

C#
public QRCode(ViewContext viewContext)
Parameters:viewContextViewContext

Properties

The background color of the QR code. Accepts a valid CSS color string, including hex and rgb.

C#
public string Background { get; set; }

The border of the QR code.

C#
public QRCodeBorderSettings Border { get; }

The color of the QR code. Accepts a valid CSS color string, including hex and rgb.

C#
public string Color { get; set; }

Specifies a QR code encoding mode.

C#
public QREncoding? Encoding { get; set; }

Specifies a QR code error correction level.

C#
public QRErrorCorrectionLevel? ErrorCorrection { get; set; }

The overlay configuration which alows you to choose from predefined layouts or insert a custom image.

C#
public QRCodeOverlaySettings Overlay { get; }

Sets the minimum distance in pixels that should be left between the border and the QR modules.

C#
public double? Padding { get; set; }

Sets the preferred rendering engine. If it is not supported by the browser, the QRCode will switch to the first available mode.The supported values are: "canvas" - renders the widget as a Canvas element, if available. or "svg" - renders the widget as inline SVG document, if available.

C#
public RenderingMode? RenderAs { get; set; }

Specifies the size of a QR code in pixels (i.e. "200px"). Numeric values are treated as pixels. If no size is specified, it will be determined from the element width and height. In case the element has width or height of zero, a default value of 200 pixels will be used.

C#
public double? Size { get; set; }

Sets the value of the QRCode. More about the value of the QRCode can be found in the Encoding documentation article.

C#
public string Value { get; set; }

Methods

Serializes the component settings to a dictionary.

C#
public override IDictionary<string, object> Serialize()
Returns:

IDictionary<string, object>

A dictionary of settings.

Overrides: WidgetBase.Serialize()

SerializeSettings method.

C#
protected override Dictionary<string, object> SerializeSettings()
Returns:

Dictionary<string, object>

Overrides: WidgetBase.SerializeSettings()

Writes the HTML content.

C#
protected override void WriteHtml(TextWriter writer)
Parameters:writerTextWriter

The text writer.

Overrides: WidgetBase.WriteHtml(TextWriter)

WriteInitializationScript method.

C#
public override void WriteInitializationScript(TextWriter writer)
Parameters:writerTextWriter

Overrides: WidgetBase.WriteInitializationScript(TextWriter)