Sketch API Reference

class ipysketch_lite.Sketch(width: int = 400, height: int = 300)

Sketch class to create a sketch instance This includes a template that allows for basic drawing utilities

property array

Get the sketch image data as a numpy array

property data: str

Get the sketch image data as a base64 encoded string

property image

Get the sketch image data as a PIL image

save(path: str)

Save the sketch image data to a file

class ipysketch_lite.SketchPad(**kwargs)

SketchPad class to create a sketchpad instance This includes a template that allows for using different tools to draw on the sketchpad

property array

Get the sketch image data as a numpy array

property data: str

Get the sketch image data as a base64 encoded string

property image

Get the sketch image data as a PIL image

save(path: str)

Save the sketch image data to a file