rectangle-example.js

total 0
used 0
limit 0
/* title: Most Minimal Example categories: minimal files: head point pointlist stage stroke ../point_src/rectangle.js --- The minimal requirements include the _head_, _stage_, and the _point_. */ class MainStage extends Stage { canvas = 'playspace' mounted() { this.points = PointList.generate.list(8, new Point(100, 0), new Point(100, 200)) this.points.each.radius = 15 this.point = this.points[2].copy() this.point.radius = 30 } draw(ctx){ this.clear(ctx) // this.points.pen.rect(ctx,{width: 4, color: '#444'}) this.points.pen.rectangles(ctx, {color:'purple'}) this.point.pen.rectangle(ctx, { width: 60 , color: '#8f6faf' , radii:[7] , strokeWidth: 1 }) // this.point.pen.rect(ctx, {color: '#8f6faf'}) } } stage = MainStage.go(/*{ loop: true }*/)
Run
Meta Data
title Most Minimal Example
imports ()
files ('head', 'point', 'pointlist', 'stage', 'stroke', '../point_src/rectangle.js')
unused_keys ()
unknown_keys ('categories',)
categories ['minimal']
filepath_exists True
path rectangle-example.js
filepath rectangle-example.js
clean_files ('../point_src/core/head.js', '../point_src/pointpen.js', '../point_src/compass.js', '../point_src/center.js', '../point_src/point-content.js', '../point_src/pointdraw.js', '../point_src/relative-xy.js', '../point_src/pointcast.js', '../point_src/point.js', '../point_src/pointlistdraw.js', '../point_src/pointlistgradient.js', '../point_src/pointlistshape.js', '../point_src/pointlistgenerator.js', '../point_src/unpack.js', '../point_src/pointlist.js', '../point_src/pointlistpen.js', '../point_src/stage-resize.js', '../point_src/functions/resolve.js', '../point_src/stage.js', '../point_src/setunset.js', '../point_src/stroke.js', '../point_src/rectangle.js')
markdown {'html': '<p>The minimal requirements include the <em>head</em>, <em>stage</em>, and the <em>point</em>.</p>', 'content': 'title: Most Minimal Example\ncategories: minimal\nfiles:\n head\n point\n pointlist\n stage\n stroke\n ../point_src/rectangle.js\n---\n\nThe minimal requirements include the _head_, _stage_, and the _point_.'}