CanvasAlgebra

doodle.svg.algebra.CanvasAlgebra
See theCanvasAlgebra companion object

Attributes

Companion
object
Source
CanvasAlgebra.scala
Graph
Supertypes
trait Redraw[Canvas]
trait MouseMove[Canvas]
class Object
trait Matchable
class Any
Show all
Known subtypes
object CanvasAlgebra

Members list

Value members

Concrete methods

def mouseClick(canvas: Canvas): Stream[IO, Point]

Return a stream that has an event every time the mouse is clicked on the canvas. The coordinate system used is the global coordinate system used by the Canvas, which usually means the origin is centered on the canvas.

Return a stream that has an event every time the mouse is clicked on the canvas. The coordinate system used is the global coordinate system used by the Canvas, which usually means the origin is centered on the canvas.

On systems, such as the browser, that will emulate touch events as mouse events this will also return such touch events.

Attributes

Source
CanvasAlgebra.scala
def mouseMove(canvas: Canvas): Stream[IO, Point]

Return a stream that has an event every time the mouse moves across the canvas. The coordinate system used is the global coordinate system used by the Canvas, which usually means the origin is centered on the canvas.

Return a stream that has an event every time the mouse moves across the canvas. The coordinate system used is the global coordinate system used by the Canvas, which usually means the origin is centered on the canvas.

Attributes

Source
CanvasAlgebra.scala
def redraw(canvas: Canvas): Stream[IO, Int]

Return a stream that has an event every time the canvas is ready to redraw. The value is the approximate time in millisecond since a frame was last rendered.

Return a stream that has an event every time the canvas is ready to redraw. The value is the approximate time in millisecond since a frame was last rendered.

Attributes

Source
CanvasAlgebra.scala