CanvasJs

ostrat.pSJs.CanvasJs$
object CanvasJs extends CanvasTopLeft

An implementation of CanvasPlatform for Scala.js using Web canvas.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Concise view

Value members

Concrete methods

override def clear(colour: Colour): Unit

Attributes

Definition Classes
override def gcRestore(): Unit

Restore GraphicContext usually used for the Clip Frame. Nothing to do with file loading.

Restore GraphicContext usually used for the Clip Frame. Nothing to do with file loading.

Attributes

Definition Classes
override def gcSave(): Unit

Save GraphicContext state usually used for the Clip Frame. Nothing to do with file saving.

Save GraphicContext state usually used for the Clip Frame. Nothing to do with file saving.

Attributes

Definition Classes
def getButton(e: MouseEvent): MouseButton
def getButtons(e: MouseEvent): MouseButton
override def getTime: Long

Returns the system (Unix) time in milliseconds.

Returns the system (Unix) time in milliseconds.

Attributes

Definition Classes
override def height: Double

Attributes

Definition Classes
override def loadFile(fileName: String): EMon[String]

Attributes

Definition Classes
override def saveFile(fileName: String, output: String): Unit

Attributes

Definition Classes
def setup(): Unit
override def timeOut(f: () => Unit, millis: Integer): Unit

A call back timer. Takes the delay in milliseconds

A call back timer. Takes the delay in milliseconds

Attributes

Definition Classes
override def tlPolyDraw(pd: PolygonDraw): Unit

Attributes

Definition Classes
override def width: Double

Attributes

Definition Classes

Inherited methods

def animSeq(anims: Seq[DispPhase]): Unit

Attributes

Inherited from:
CanvasPlatform
final override def bezierDraw(bd: BezierDraw): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft

Attributes

Inherited from:
OrdinalEdgePoints

Attributes

Inherited from:
RectCenlign
final override def bottomLeft: Pt2

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def bottomRight: Pt2

Attributes

Definition Classes
Inherited from:
RectCenlign

Attributes

Inherited from:
OrdinalEdgePoints
final override def cArcDraw(cad: CArcDraw): Unit

Draws a circular arc on the canvas.

Draws a circular arc on the canvas.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
override def cen: Pt2

The centre of this geometric / graphical element. The centre will not change if the object type is capable of being rotated and is rotated. The cenDefault on other bounded elements may move relative to points on the object when the object is rotated.

The centre of this geometric / graphical element. The centre will not change if the object type is capable of being rotated and is rotated. The cenDefault on other bounded elements may move relative to points on the object when the object is rotated.

Attributes

Definition Classes
Inherited from:
RectCenlign

Attributes

Inherited from:
RectCenlign

The X component of the centre.

The X component of the centre.

Attributes

Inherited from:
RectCenlign

The Y component of the centre.

The Y component of the centre.

Attributes

Inherited from:
RectCenlign
final override def circleDraw(cd: CircleDraw): Unit

Side effecting procedure that draws a circle on the screen. Implemented by the target platform.

Side effecting procedure that draws a circle on the screen. Implemented by the target platform.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def circleFill(cf: CircleFill): Unit

Side effecting procedure that fills a circle. Implemented by the target platform.

Side effecting procedure that fills a circle. Implemented by the target platform.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def circleFillRadial(circle: Circle, fill: FillRadial): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def clip(pts: Polygon): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
def crossHairs(lineWidth: Double, lineColour: Colour): LinesDraw

Attributes

Inherited from:
RectCenlign
final override def dashedLineDraw(dld: DashedLineDraw): Unit

To be removed from CanvasPlatform.

To be removed from CanvasPlatform.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def eArcDraw(ead: EArcDraw): Unit

Draws an elliptical arc on the canvas.

Draws an elliptical arc on the canvas.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def ellipseDraw(ed: EllipseDraw): Unit

Side effecting procedure that draws an ellipse on the screen. Implemented by the target platform.

Side effecting procedure that draws an ellipse on the screen. Implemented by the target platform.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def ellipseFill(ef: EllipseFill): Unit

Side effecting procedure that fills an ellipse on the screen. Implemented by the target platform.

Side effecting procedure that fills an ellipse on the screen. Implemented by the target platform.

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
def frame(f: (Integer, Integer) => Unit, startTime: Integer, frameLength: Integer): Unit

A callback timer with an elapsed time from a given start point. Although are in a general purpose form, the most common usage is for animations where things move dependent on how much time has passed. The function is of form: (elapsedTime(in milliseconds), Startime (in milliseconds) => Unit. The startTime is to be used to call the next frame at then end of the function, if another frame is needed.

A callback timer with an elapsed time from a given start point. Although are in a general purpose form, the most common usage is for animations where things move dependent on how much time has passed. The function is of form: (elapsedTime(in milliseconds), Startime (in milliseconds) => Unit. The startTime is to be used to call the next frame at then end of the function, if another frame is needed.

Attributes

Inherited from:
CanvasPlatform
def fromFileFind[A](fileName: String)(implicit ev: Unshow[A]): EMon[A]

Attributes

Inherited from:
CanvasPlatform
def fromFileFindElse[A](fileName: String, elseValue: => A)(implicit ev: Unshow[A]): A

Attributes

Inherited from:
CanvasPlatform
def fromFileFindForeach[A](fileName: String, f: A => Unit)(implicit ev: Unshow[A]): Unit

Attempts to find find and load file, attempts to parse the file, attempts to find object of type A. If all stages successful, calls procedure (Unit returning function) with that object of type A

Attempts to find find and load file, attempts to parse the file, attempts to find object of type A. If all stages successful, calls procedure (Unit returning function) with that object of type A

Attributes

Inherited from:
CanvasPlatform
def fromFileFindSetting[A](settingStr: String, fileName: String)(implicit ev: Unshow[A]): EMon[A]

Attributes

Inherited from:
CanvasPlatform
def fromFileFindSettingElse[A](settingStr: String, fileName: String, elseValue: => A)(implicit ev: Unshow[A]): A

Attributes

Inherited from:
CanvasPlatform
def gridLines(spacing: Double, colour: Colour, lineWidth: Double): LinesDraw

Not sure why spacing has got a minus sign

Not sure why spacing has got a minus sign

Attributes

Inherited from:
RectCenlign
def gridLines2Colours(spacing: Double, cenColour: Colour, otherColour: Colour, lineWidth: Double): RArr[LinesDraw]

Badly named I think, not sure why spacing has got a minus sign

Badly named I think, not sure why spacing has got a minus sign

Attributes

Inherited from:
RectCenlign

Attributes

Inherited from:
RectCenlign

Attributes

Inherited from:
CanvasPlatform
final override def lineSegDraw(ld: LineSegDraw): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def lineSegsDraw(lsd: LinesDraw): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft

Attributes

Inherited from:
CanvasTopLeft
final override def pLinePathDraw(pod: LinePathDraw): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def pPolyDraw(pd: PolygonDraw): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def pPolyFill(pf: PolygonFill): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def pShapeGenDraw(sgd: ShapeGenDrawOld): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def pShapeGenFill(sgf: ShapeGenFillOld): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft

Attributes

Inherited from:
RectCenlign
final def polygonDraw(pd: PolygonDraw): Unit

Attributes

Inherited from:
CanvasPlatform
final def polygonFill(pf: PolygonFill): Unit

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
RectCenlign

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
CanvasPlatform
def startFrame(f: (Integer, Integer) => Unit, frameLength: Integer): Unit

The initial frame although are in a general purpose form, the most common usage is for animations where things move dependent on how much time has passed.

The initial frame although are in a general purpose form, the most common usage is for animations where things move dependent on how much time has passed.

Attributes

Inherited from:
CanvasPlatform
def startFramePermanent(f: Integer => Unit, millis: Integer): Unit

Attributes

Inherited from:
CanvasPlatform
final override def textGraphic(tg: TextGraphic): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
final override def textOutline(tl: TextOutline): Unit

Attributes

Definition Classes
Inherited from:
CanvasTopLeft
def tlCen: Pt2 => Pt2

Attributes

Inherited from:
CanvasTopLeft

Attributes

Inherited from:
OrdinalEdgePoints
def toBL(input: Pt2): Pt2

Attributes

Inherited from:
CanvasPlatform
def top: Double

Attributes

Inherited from:
RectCenlign
final override def topLeft: Pt2

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def topRight: Pt2

Attributes

Definition Classes
Inherited from:
RectCenlign

Top right offset from centre.

Top right offset from centre.

Attributes

Inherited from:
OrdinalEdgePoints
final override def xBottomLeft: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def xBottomRight: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def xTopLeft: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def xTopRight: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def yBottomLeft: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def yBottomRight: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def yTopLeft: Double

Attributes

Definition Classes
Inherited from:
RectCenlign
final override def yTopRight: Double

Attributes

Definition Classes
Inherited from:
RectCenlign

Concrete fields

val can: Canvas
val gc: CanvasRenderingContext2D

Inherited fields

Attributes

Inherited from:
CanvasPlatform
var keyUp: String => Unit

Attributes

Inherited from:
CanvasPlatform

The canvas implementation will call this function when the mouse button is depressed. Named after Javascript command.

The canvas implementation will call this function when the mouse button is depressed. Named after Javascript command.

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
CanvasPlatform

The canvas implementation will call this function when a mouse button is released. Named after Javascript command.

The canvas implementation will call this function when a mouse button is released. Named after Javascript command.

Attributes

Inherited from:
CanvasPlatform

Attributes

Inherited from:
CanvasPlatform
var resize: () => Unit

Attributes

Inherited from:
CanvasPlatform