Skip to end of metadata
Go to start of metadata

Represents a signature canvas control.

Definition

public class UISignatureCanvasView : UIViewBase

Summary

The following table summarizes the members exposed in this class.

Public Constructors

UISignatureCanvasView Constructor() Initializes a new instance of the UISignatureCanvasView class.
UISignatureCanvasView Constructor(IntPtr) Initializes a new instance of the UISignatureCanvasView class.
UISignatureCanvasView Constructor(NSObjectFlag) Initializes a new instance of the UISignatureCanvasView class.
UISignatureCanvasView Constructor(CGRect) Initializes a new instance of the UISignatureCanvasView class.
UISignatureCanvasView Constructor(NSCoder) Initializes a new instance of the UISignatureCanvasView class.

Public Properties

ByteArray Gets or sets the byte array.
SnapShot Gets or sets the snap shot.
StrokeColor Gets or sets the color of the stroke.
StrokeWidth Gets or sets the width of the stroke.

Public Methods

Draw(CGRect) Draws the view within the passed-in rectangle.
UpdateByte() Updates the byte.

Protected Methods

Dispose(bool) Called when this control is disposing.
Initialize() Called when this control is initializing.
OnPropertyChanged(string) Raises the property changed event.

Events

SignatureChangedEvent Occurs when [signature changed event].

Public Constructors

public UISignatureCanvasView()

Initializes a new instance of the UISignatureCanvasView class.

public UISignatureCanvasView(IntPtr handle)

Initializes a new instance of the UISignatureCanvasView class.

Parameters

handle Handle.

public UISignatureCanvasView(NSObjectFlag t)

Initializes a new instance of the UISignatureCanvasView class.

Parameters

t T.

public UISignatureCanvasView(CGRect frame)

Initializes a new instance of the UISignatureCanvasView class.

Parameters

frame Frame.

public UISignatureCanvasView(NSCoder coder)

Initializes a new instance of the UISignatureCanvasView class.

Parameters

coder Coder.

Public Properties

public Byte[] ByteArray { get; set; }

Gets or sets the byte array.

public UIImage SnapShot { get; set; }

Gets or sets the snap shot.

public UIColor StrokeColor { get; set; }

Gets or sets the color of the stroke.

public nfloat StrokeWidth { get; set; }

Gets or sets the width of the stroke.

Public Methods

public void Draw(CGRect rect)

Draws the view within the passed-in rectangle.

Remarks

The UIKit.UIView.Draw method should never be called directly. It is called by iOS during run loop processing. The first time through the run loop, it is called. After that, it will be called on demand whenever the view has been marked as needing display by calling UIKit.UIView.SetNeedsDisplay or UIKit.UIView.SetNeedsDisplayInRect(System.Drawing.RectangleF). Core Graphics uses device independent points rather than pixels. This allows drawing code to scale between different resolutions. For example, on a Retina display, 1 point is equivalent to 2 pixels, while on non-Retina displays, 1 point corresponds to 1 pixel. public override void Draw (RectangleF rect) { base.Draw (rect); var context = UIGraphics.GetCurrentContext (); context.SetLineWidth(4); UIColor.Red.SetFill (); UIColor.Blue.SetStroke (); var path = new CGPath (); path.AddLines(new PointF[]{ new PointF(100,200), new PointF(160,100), new PointF(220,200)}); path.CloseSubpath(); context.AddPath(path); context.DrawPath(CGPathDrawingMode.FillStroke); } This can be used from a background thread.

Parameters

rect The System.Drawing.RectangleF to draw.

public void UpdateByte()

Updates the byte.

Protected Methods

protected void Dispose(bool disposing)

Called when this control is disposing.

Parameters

disposing If set to true disposing.

protected void Initialize()

Called when this control is initializing.

protected void OnPropertyChanged(string propertyName)

Raises the property changed event.

Parameters

propertyName Property name.

Events

public event EventHandler SignatureChangedEvent

Occurs when [signature changed event].

  • No labels