RadSignaturePad
Provides support for drawing and saving signatures.
Definition
Namespace:Telerik.Maui.Controls
Assembly:Telerik.Maui.Controls.dll
Syntax:
public class RadSignaturePad : RadBorder, IRadBorder, IRadContentView, IContentView, IView, IElement, ITransform, IPadding, ICrossPlatformLayout
Inheritance: objectRadContentViewRadBorderRadSignaturePad
Implements:
Inherited Members
Constructors
Initializes a new instance of the RadSignaturePad class.
public RadSignaturePad()
Fields
ActualStyleProperty
BindableProperty
Identifies the ActualStyle property.
public static readonly BindableProperty ActualStyleProperty
BackgroundColorProperty
BindableProperty
Identifies the BackgroundColor property.
public static readonly BindableProperty BackgroundColorProperty
StrokeColorProperty
BindableProperty
Identifies the StrokeColor property.
public static readonly BindableProperty StrokeColorProperty
StrokeThicknessProperty
BindableProperty
Identifies the StrokeThickness property.
public static readonly BindableProperty StrokeThicknessProperty
StyleProperty
BindableProperty
Identifies the Style property.
public static readonly BindableProperty StyleProperty
Properties
ActualStyle
Style
Gets the result from merging the Style property with the default Style of the control.
public Style ActualStyle { get; }
BackgroundColor
Color
public Color BackgroundColor { get; set; }
Gets a command to clear the RadSignaturePad.
<telerik:RadSignaturePad x:Name="signaturePad" />
<Button Text="Clear" Command="{Binding Source={x:Reference signaturePad}, Path=ClearCommand}" />
public ICommand ClearCommand { get; }
StrokeColor
Color
Gets or sets the stroke color for the signature.
public Color StrokeColor { get; set; }
Gets or sets the stroke thickness for the signature.
public double StrokeThickness { get; set; }
Methods
Saves drawn signature to the specified stream, encoding it using the provided SaveImageSettings.
public Task SaveImageAsync(Stream outputStream, SaveImageSettings settings)
Specifies the output stream to save the image to.
settingsSaveImageSettingsSpecifies the SaveImageSettings to be used for encoding the image.
Returns:Returns a Task to await the asynchronous operation.
Exceptions:The image buffer data is null.
The image buffer data count is negative number.
An I/O error occured, such as the specified file cannot be found.
The outputStream does not support writing.
Writing to outputStream is called after the stream was closed.
Unable to allocate pixels for the bitmap. Can occur with big values for ScaleFactor.
Saves drawn signature to the specified stream, encoding it as Png, using the RadSignaturePad's , StrokeColor and StrokeThickness.
public Task SaveImageAsync(Stream outputStream)
Specifies the output stream to save the image to.
Returns:Returns a Task to await the asynchronous operation.
Exceptions:The image buffer data is null.
The image buffer data count is negative number.
An I/O error occured, such as the specified file cannot be found.
The outputStream does not support writing.
Writing to outputStream is called after the stream was closed.
Events
Raised when the surface of RadSignaturePad is cleared.
public event EventHandler Cleared
Raised when a new stroke is completed in RadSignaturePad.
public event EventHandler StrokeCompleted
Raised when a new stroke is started in RadSignaturePad.
public event EventHandler StrokeStarted