pas2js/demo/modules/flat-units/canvas.pp
Michaël Van Canneyt 0c4ac1b113 * Module demos
2021-09-11 14:59:41 +02:00

23 lines
517 B
ObjectPascal

{$linklib ./modules/canvas.js canvas}
{$mode objfpc}
{$modeswitch externalclass}
unit canvas;
interface
uses js, web;
Type
TCreateCanvasResult = class external name 'Object' (TJSObject)
ctx: TJSCanvasRenderingContext2D;
id : string;
end;
function create (aID : String; AParent : TJSElement; aWidth,aHeight : Integer) : TCreateCanvasResult; external name 'canvas.create';
function createReportList(aWrapperID : String) : String; external name 'canvas.createReportList';
implementation
end.