DrawsanaView

public class DrawsanaView : UIView

Add this view to your view hierarchy to get going with Drawsana!

  • Set the active tool to a new value. If you pass shape, it is passed on to the tool’s DrawingTool.activate(context:shape:) method.

    Declaration

    Swift

    public func set(tool: DrawingTool, shape: Shape? = nil)
  • Render the drawing on top of an image, using that image’s size. Shapes are re-scaled to match the resolution of the target without artifacts.

    Declaration

    Swift

    public func render(over image: UIImage?) -> UIImage?
  • Render the drawing. If you pass a size, shapes are re-scaled to be full resolution at that size, otherwise the view size is used.

    Declaration

    Swift

    public func render(size: CGSize? = nil) -> UIImage?